;****************** SPECIAL FLAGS AND RAM USAGE ******************	    
;THE HERO USES HIS STATE VARIABLE TO SAVE THE REGISTER DURING AN INTERRUPT.
;
;COMMON DATA RAM IS USED AS FOLLOWS IN THIS GAME (BIBLE GAME)
;
;1 = WORLD CONTINUE
;2-24 26-49 = UNUSED

;25 = GOAL COUNTER
;50 = NUMBER OF BODIES IN HAND
;51 = WORLD TIMER
;52 = UNUSED
;53 = NUMBER SAVED	
;54 = NUMBER LOST

;55 = NUMBER LAUNCHED
;56 = BIRD Y LOCATION
;57 = WORLD JUST FINISHED
;58 = BOSS DEAD OR NOT 0=ALIVE 1=DEAD
;60 = MUSIC SELECT 0=OFF 1=ON
;61 = MISC COUNTER
;----------------------------------------------
;THIS CODE NOT ONLY LAUNCHES THE LITTLE MEN BUT ALSO PRINTS "SCORE" "HANDS"
;"CAUGHT" "TIMER" "SAVED" AND "QUOTA" ONTO THE SCREEN. ITS IN THE SAME
;LOCATION FOR EVERY WORLD.

DUDEMAKE:
	.DRW	DUMMY,MAKER
	.DB	0,-1,0,0,0

MAKER: 
;FIRST DO A WHOLE BUNCH 'O CRAP...

	.DB	INSTRUCTIONS,22
	.DB	GRAVITY,0
	.DB	DISSCROLL,UP|DOWN

	.DB	SETREG,0,0
	.DB	STORE,50 	;ZERO HAND COUNT
	.DB	STORE,51	;ZERO COUNTER
	.DB	STORE,25	;ZERO GOAL COUNT
	.DB	STORE,53 	;ZERO SAVED COUNT
	.DB	STORE,55	;ZERO LAUNCH COUNT

	.DB	WRITEVID	       
	.DRW	SCORES
	.DB	15,1,0,5
	.DB	WRITEVID
	.DRW	CAUGHT
	.DB	19,1,0,6
	.DB	WRITEVID
	.DRW	HANDTEXT
	.DB	23,1,0,5
	.DB	GETHEROS,JOY1
	.DB	SHOWREG,24,1,0
	.DB	WRITEVID
	.DRW	TIME
	.DB	15,26,0,5
	.DB	WRITEVID	       
	.DRW	SAVED
	.DB	19,26,0,5
	.DB	LOAD,53
	.DB	SHOWREG,20,26,0		;PRINT OUT NUMBER SAVED (ZERO)
	.DB	WRITEVID	;PRINT OUT "QUOTA" AND RESPECTIVE NUMBER	       
	.DRW	GOAL
	.DB	23,26,0,5
	.DB	FETCHREG,PARAM2
	.DB	STORE,25
	.DB	SHOWREG,24,26,0

;...NOW MAKE LITTLE ENTITIES

	.DB	INSTRUCTIONS,3
	.DB	FETCHREG,WORLD
	.DB	CASE
	.DRW	MAK10,1		;I-BEAM WORLD
	.DRW	MAK70,2		;PARACHUTE/LEAF WORLD
	.DRW	MAK90,3		;PIPES WORLD
	.DRW	MAK35,4		;LADDER/SNIPER WORLD
	.DRW	MAK20,5		;JUNGLE WORLD
	.DRW	SAFEDIE,6 	;MOUTH WORLD MOUTH LAUNCHES MEN
	.DRW	MAK30,7		;CANNON WORLD
	.DRW	MAK80,8		;FIRE WORLD
	.DRW	MAK100,9	;BUNGEE/BIG FOOT WORLD
	.DRW	MAK80,10 	;PLATFORMS WORLD
	.DRW	MAK110,11	;TRASH WORLD
	.DRW	MAK130,12	;DYNAMITE WORLD
	.DRW	MAK120,13	;SNAKE WORLD
	.DRW	MAK140,14	;HORNS WORLD
	.DRW	MAK150,15	;POPCORN WORLD
	.DRW	0	
	
	.DB	DIE,0
;--------------------------------I-BEAM WORLD

MAK10: 
	.DB	RANDOM
	.DRW	MAK11
	.DB	20	       		;20
	.DB	HOWMANY,3
	.DB	COMPARE
	.DRW	MAK10
	.DRW	6
	.DB	LAUNCH,3,0,0,0	    	;3 MAKE DUDES
	.DB	SKIP
	.DRW	MAK12

MAK11: 
	.DB	RANDOM
	.DRW	MAK11A
	.DB	50	       
	.DB	LAUNCH,7,0,0,0		;7 MAKE DUCKIES
	.DB	SKIP
	.DRW	MAK12
MAK11A:	.DB	RANDOM
	.DRW	MAK11B
	.DB	127
	.DB	LAUNCH,39,0,0,0		;39 LAUNCH JET
	.DB	SKIP
	.DRW	MAK12
MAK11B:	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER
MAK12:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	90
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	MAK10  

;----------------------JUNGLE WORLD

MAK20:	.DB	HOWMANY,8
	.DB	COMPARE
	.DRW	MAK20
	.DRW	4
	.DB	RANDOM	
	.DRW	MAK21
	.DB	40
	.DB	LAUNCH,8,0,4,0	    	;MAKE DUDES
	.DB	SKIP
	.DRW	MAK22
MAK21:	.DB	LAUNCH,42,0,0,0	    	;LAUNCH HOPPER
MAK22:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	80
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	MAK20  

;-----------------CANNON WORLD

MAK30: 
	.DB	HOWMANY,9
	.DB	COMPARE
	.DRW	MAK30
	.DRW	5
	.DB	RANDOM
	.DRW	MAK31
	.DB	20	
	.DB	LAUNCH,9,0,0,0	    	;MAKE DUDES
	.DB	SKIP
	.DRW	MAK32
MAK31:
	.DB	RANDOM
	.DRW	MAK31A
	.DB	50
	.DB	LAUNCH,7,0,0,0		;MAKE DUCKIES
	.DB	SKIP
	.DRW	MAK32
MAK31A:	.DB	RANDOM
	.DRW	MAK31B
	.DB	127
	.DB	LAUNCH,39,0,0,0		;LAUNCH JET
	.DB	SKIP
	.DRW	MAK32
MAK31B:	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER
MAK32:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	110
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	MAK30  

;-----------------LADDER/SNIPER WORLD

MAK35:
 	.DB	CREATE,13,120,40,0 
MAK37: 	.DB	RANDOM
	.DRW	MAK66
	.DB	20
	.DB    	RANDOM
	.DRW	MAK50
	.DB	127
	
MAK40:	.DB	RANDOM	    		;LEFT SIDE
	.DRW	MAK41
	.DB	150
	.DB	GOTO,64,64		
	.DB	SKIP
	.DRW	MAK60
MAK41:	.DB	RANDOM
	.DRW	MAK42
	.DB	127
	.DB	GOTO,64,96		
	.DB	SKIP
	.DRW	MAK60
MAK42:	.DB	GOTO,64,128		
	.DB	SKIP
	.DRW	MAK60

MAK50:	.DB	RANDOM	       		;RIGHT SIDE
	.DRW	MAK51
	.DB	150
	.DB	GOTO,176,80		
	.DB	SKIP
	.DRW	MAK60
MAK51:	.DB	RANDOM
	.DRW	MAK52
	.DB	127
	.DB	GOTO,176,112		
	.DB	SKIP
	.DRW	MAK60
MAK52: 	.DB	GOTO,176,144		

MAK60:	.DB	LAUNCH,11,0,0,0	      	;SNIPER
MAK65:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	90
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	MAK35

MAK66:	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER
	.DB	SKIP
	.DRW	MAK35
;----------------------------------PARACHUTE/LEAF WORLD

MAK70: 	.DB	RANDOM
	.DRW	MAK71
	.DB	20
	.DB	HOWMANY,15
	.DB	COMPARE
	.DRW	MAK70
	.DRW	5
	.DB	LAUNCH,15,0,0,0	    	;MAKE DUDES
	.DB	SKIP
	.DRW	MAK73
MAK71:
	.DB	RANDOM
	.DRW	MAK72
	.DB	50
	.DB	LAUNCH,7,0,-13,0		;MAKE DUCKIES
	.DB	SKIP
	.DRW	MAK73
MAK72: 	.DB	RANDOM
	.DRW	MAK72A
	.DB	127
	.DB	LAUNCH,39,0,-16,0		;LAUNCH JET
	.DB	SKIP
	.DRW	MAK73
MAK72A:	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER
MAK73:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	90
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	MAK70  

;---------------------PLATFORMS FIRE AND MOUTH WORLD


MAK80:	.DB	LAUNCH,19,0,0,0	   	;LAUNCH DUDES
MAK85: 	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	73
	.DB	DELAY,REGISTER
	.DB	RANDOM
	.DRW	MAK80
	.DB	235

	.DB	RANDOM
	.DRW	MAK86
	.DB	50
	.DB	LAUNCH,7,0,0,0		;MAKE DUCKIES
	.DB	SKIP
	.DRW	MAK80
MAK86: 	.DB	RANDOM
	.DRW	MAK87
	.DB	127
	.DB	LAUNCH,39,0,0,0		;LAUNCH JET
	.DB	SKIP
	.DRW	MAK80
MAK87:	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER
	.DB	SKIP
	.DRW	MAK80

;------------------------PIPE WORLD
MAK90:
	.DB	RANDOM
	.DRW	MAK95
	.DB	20
	.DB	LAUNCH,23,0,0,0	      	;LAUNCH MEN
	.DB	SKIP
	.DRW	MAK96
MAK95:	.DB	RANDOM
	.DRW	MAK95A
	.DB	50
	.DB	LAUNCH,7,0,0,0		;MAKE DUCKIES
	.DB	SKIP
	.DRW	MAK96
MAK95A:	.DB	RANDOM
	.DRW	MAK95B
	.DB	127
	.DB	LAUNCH,39,0,0,0		;LAUNCH JET
	.DB	SKIP
	.DRW	MAK96
MAK95B:	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER
MAK96:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	80
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	MAK90

;-------------------------BUNGEE WORLD

MAK100:	.DB	ACTIVE 		;IF JUMPER OUT, DON'T LAUNCH ANOTHER
	.DRW	MAK100
	.DB	ID
	.DRW	26	
	
	.DB	DELAY,7
	.DB	RANDOM
	.DRW	MAK101
	.DB	50
	.DB	LAUNCH,26,0,0,0	  	;BUNGEE BOY!
	.DB	SKIP
	.DRW	MAK100
MAK101:	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER			
	.DB	SKIP
	.DRW	MAK100

;-------------------------------TRASH CAN WORLD

MAK110:	.DB	ACTIVE
	.DRW	MAK115
	.DB	ID
	.DRW	16

	.DB	RANDOM
	.DRW	MAK111
	.DB	30
	.DB	LAUNCH,16,0,0,0		;LAUNCH TRASH
	.DB	SKIP
	.DRW	MAK115
MAK111:
	.DB	RANDOM
	.DRW	MAK112
	.DB	50
	.DB	LAUNCH,7,0,0,0		;MAKE DUCKIES
	.DB	SKIP
	.DRW	MAK115
MAK112:	.DB	RANDOM
	.DRW	MAK113
	.DB	127
	.DB	LAUNCH,39,0,0,0		;LAUNCH JET
	.DB	SKIP
	.DRW	MAK115
MAK113:	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER
MAK115:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	110
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	MAK110


;--------------------------------------SNAKE WORLD
MAK120:	.DB	LAUNCH,29,0,0,0
	.DB	RANDOM
	.DRW	MAK125
	.DB	200
	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER
MAK125:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	90
	.DB	DELAY,REGISTER
	.DB	RANDOM
	.DRW	MAK120
	.DB	230
	.DB	NOISE
	.DRW	SNKSND
	.DB	SKIP
	.DRW	MAK120

;----------------------------------DYNAMITE WORLD
MAK130:
	.DB	ACTIVE
	.DRW	MAK130
	.DB	ID	
	.DRW	30
	.DB	ACTIVE
	.DRW	MAK130
	.DB	ID	
	.DRW	31
	
	.DB	RANDOM
	.DRW	MAK135
	.DB	50
	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	70
	.DB	DELAY,REGISTER
	.DB	LAUNCH,30,0,0,0	    	;LAUNCH DYNAMITE
	.DB	SKIP
	.DRW	MAK130
MAK135:	.DB	RANDOM
	.DRW	MAK136
	.DB	75
	.DB	LAUNCH,7,0,0,0		;MAKE DUCKIES
	.DB	SKIP
	.DRW	MAK130
MAK136:	.DB	RANDOM
	.DRW	MAK137
	.DB	127		
	.DB	LAUNCH,42,0,0,0		
	.DB	SKIP
	.DRW	MAK130
MAK137:	.DB	LAUNCH,39,0,0,0
	.DB	SKIP
	.DRW	MAK130

;------------------------HORNS WORLD
MAK140:
	.DB	RANDOM
	.DRW	MAK145
	.DB	30
	.DB	LAUNCH,40,0,0,0	      	;LAUNCH MEN
	.DB	SKIP
	.DRW	MAK146
MAK145:	.DB	RANDOM
	.DRW	MAK145A
	.DB	70
	.DB	LAUNCH,7,0,0,0		;MAKE DUCKIES
	.DB	SKIP
	.DRW	MAK146
MAK145A:.DB	RANDOM
	.DRW	MAK145B
	.DB	35
	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPER
	.DB	SKIP
	.DRW	MAK146
MAK145B:.DB	LAUNCH,39,0,0,0		;LAUNCH JET
MAK146:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	50
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	MAK140

;------------------------POPCORN WORLD
MAK150:
	.DB	RANDOM
	.DRW	MAK155
	.DB	50
	.DB	LAUNCH,41,0,0,0	      	;LAUNCH MEN
	.DB	SKIP
	.DRW	MAK156
MAK155:	.DB	RANDOM
	.DRW	MAK155A
	.DB	85
	.DB	LAUNCH,7,0,0,0		;MAKE DUCKIES
	.DB	SKIP
	.DRW	MAK156
MAK155A:.DB	RANDOM
	.DRW	MAK155B
	.DB	30
	.DB	LAUNCH,42,0,0,0		;LAUNCH HOPPPER	     	
	.DB	SKIP
	.DRW	MAK156
MAK155B:.DB	LAUNCH,39,0,0,0		;LAUNCH JET	     	
MAK156:	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	63
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	MAK150

;---------------------------------------------------------------------


SCORES:	.DB	"SCORE"
CAUGHT:	.DB	"CAUGHT"
HANDTEXT:.DB	"HANDS"
TIME:	.DB	"TIMER"	
SAVED:	.DB	"SAVED"
GOAL:	.DB	"QUOTA"

;------------------------------------------

TIMER:	
	.DRW	DUMMY,TIMECODE
	.DB	0,-1,0,H'20,0

TIMECODE:.DB	GRAVITY,0
	.DB	FETCHREG,PARAM2
	.DB	STORE,51
	.DB	SHOWREG,16,26,0
TIM5: 	.DB	DELAY,30
	.DB	ADD
	.DRW	-1	
	.DB	SHOWREG,16,26,0	  	;TIMER
	.DB	STORE,51
	.DB	COMPARE
	.DRW	TIM5
	.DRW	11

;CODE TO MAKE IT FLASH WHEN LOW
	.DB	DELAY,30
TIM6:	.DB	INSTRUCTIONS,7 
	.DB	ADD
	.DRW	-1	
	.DB	WRITEVID
	.DRW	FLASH
	.DB	16,26,0,5
	.DB	STORE,51
	.DB	DELAY,13
	.DB	SHOWREG,16,26,0	  	;TIMER
	.DB	DELAY,13
	.DB	EQUAL
	.DRW	TIM10
	.DRW	0
	.DB	SKIP
	.DRW	TIM6	  

TIM10:
	.DB	HURT,0,ID 	 ;HURT HAND TO DO PICTURE	
	.DRW	1
	.DB	SKIP
	.DRW	TIM10

FLASH:	.DB	"HURRY"	

;--------------------------------------------

	.DRW	SNIP3		  	;FIRING
	.DB	0
	.DRW	SNIP2			;STANDING
	.DB	0
SNIPER:	.DRW	SNIP1S,SNIPOUT
	.DB	H'40,-1,0,0,0	
	.DRW	SNIP2S,SNIPBACK
	.DB	H'40,-1,0,0,0

SNIPOUT:
	.DB	INSTRUCTIONS,11
	.DB	TARGET
	.DRW	HELPER
	.DB	XTRACK,TOWARDS
	.DB	SETMOM,2,0
	.DB	FACE,CURRENT
	.DB	SOLIDSTATE,ON
	.DB	FINISH
	.DB	ANIMATION,3,RESERVE
	.DB	DELAY,7
SNP10:	.DB	ANIMATION,6,RESERVE
     
	.DB	ACTIVE			;IF GUY THERE, SHOOT
	.DRW	SNP15
	.DB	ID
	.DRW	13
	.DB	ACTIVATE,EHURT		;IF NOT, GO AWAY
		
SNP15: 	.DB	INSTRUCTIONS,7
	.DB	LOWNOISE
	.DRW	SHOTSND
	.DB	SPAWN,12,13,-5,0 		;SHOOT BULLET
	.DB	DELAY,7
	.DB	ANIMATION,3,RESERVE
	.DB	DELAY,7
	.DB	RANDOM
	.DRW	SNP10 				;SOMETIMES SHOOT AGAIN
	.DB	127
SNP16:	.DB	ACTIVATE,EHURT

SNIPBACK:
	.DB	INSTRUCTIONS,3
	.DB	FINISH
	.DB	DELAY,3
	.DB	DIE,0

;------------------------------------------------------------------

SNBULLET:		 		;SNIPER'S BULLET
	.DRW	SNBUL,BULCODE
	.DB	0,-2,H'30,0,H'11

BULCODE:
	.DB	ACTIVE
	.DRW	BUL5
	.DB	ID
	.DRW	13
	.DB	DIE,0	

BUL5:	.DB	INSTRUCTIONS,8
	.DB	GRAVITY,0
	.DB	TARGET
	.DRW	HELPER
	.DB	XTRACK,TOWARDS
	.DB	FACE,TRAVELING
	.DB	UNLINK
	.DB	FRICTION,0,0
	.DB	SETCOUNTER,13
BUL10: 	.DB	MOVEIN,8,-1
	.DB	SETMOM,NOCHANGE,NOCHANGE
	.DB	XTRACK,NONE
	.DB	ATTACKED
	.DRW	SAFEDIE	
	.DB	ABOVECOUNT
	.DRW	BUL10
	.DB     0
	.DB	DIE,0	
	
;--------------------------------------------------------------------------

CANSMOK:
	.DRW	CANS,CANCODE
	.DB	H'40,-1,0,0,0

CANCODE:
	.DB	GRAVITY,0	;FOR VISUAL EFFECT, YOU UNDERSTAND
	.DB	FINISH
	.DB	DIE,0
	
;------------------------------------------------------------

;-------------------------------------------------------------
	.DRW	FLAME
	.DB	0
BOMBF:	.DRW	DUMMY,BOMBCODE
	.DB	0,-2,0,0,0

	.DRW	FLAME
	.DB	0
BOMB:	.DRW	DUMMY,BOMBCODE
	.DB	0,-2,0,0,0

BOMBCODE:
	.DB	GRAVITY,0
	.DB	TARGET
	.DRW	HERO0
BOMB5:	.DB	FETCHREG,RANDOM	 	;LOCATION CODE	
	.DB	COMPARE
	.DRW	BOMB7
	.DRW	69
	.DB	SKIP
	.DRW	BOMB5
BOMB7:	.DB	COMPARE
	.DRW	BOMB5
	.DRW	180

	.DB	GOTO,REGISTER,-1
	.DB	ANIMATION,3,RESERVE

BOMB10:	.DB	SETMOM,0,8
	.DB	ATTACKED
	.DRW	BOMB20
	.DB	YVISUAL
	.DRW	BOMB10
	.DB	200	

BOMB20:
	.DB	DIE,0
	
;-------------------------------------------------


PLATS:
	.DRW	PLATTY,PLATCODE
	.DB	0,-2,0,H'30,0

PLATCODE:
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	SOLIDSTATE,ON       
	.DB	TARGET
	.DRW	HELPER|SUPPLY

	.DB	RANDOM
	.DRW	PLAT10
	.DB	127
	
PLAT5: 
	.DB	RANDOM
	.DRW	PLAT6
	.DB	127
	.DB	DELAY,27

PLAT6:	.DB	SETMOM,8,0
	.DB	TESTSOLID
	.DRW	PLAT10
	.DB	3,0
	.DB	SKIP
	.DRW	PLAT6	

PLAT10:
	.DB	RANDOM
	.DRW	PLAT11
	.DB	127
	.DB	DELAY,27


PLAT11:
	.DB	SETMOM,-8,0
	.DB	TESTSOLID
	.DRW	PLAT5
	.DB	-3,0
	.DB	SKIP
	.DRW	PLAT11

;------------------------------------------------------------------------

BOMBDUM:
	.DRW	DUMMY,BOMBDROP
	.DB	0,-1,0,0,0

BOMBDROP:
   	.DB	GRAVITY,0

BMB10:	.DB	FETCHREG,RANDOM	 	;LOCATION CODE	
	.DB	COMPARE
	.DRW	BMB15
	.DRW	69
	.DB	SKIP
	.DRW	BMB10
BMB15:	.DB	COMPARE
	.DRW	BMB10
	.DRW	180

	.DB	GOTO,REGISTER,-1
	.DB	LAUNCH,22,0,0,0
	.DB	FETCHREG,RANDOM
	.DB	LIMIT
	.DRW	53
	.DB	DELAY,REGISTER
	.DB	SKIP
	.DRW	BMB10
;---------------------------------------------------------------------
	.DRW	MANWALK 	    ;15
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MAN7
	.DB	0
	.DRW	MANS3
	.DB	0
	.DRW	MANS1
	.DB	0
DUDER:	.DRW	DUMMY,DUDCODE
	.DB	0,-1,0,H'00,0
	.DRW	-1,DHURT
	.DB	H'40,-1,0,0,0
	.DRW	DUMMY,DFALL   
	.DB	H'40,-1,0,0,0

DUDCODE:
	.DB	IDENTIFY
	.DRW	KILLER
	.DB	GRAVITY,-1		       ;WALKING CODE
	.DB	MOMLIMIT,8,1
	.DB	FRICTION,0,0
	.DB	ENABLE,HURTING
DUD08:	.DB	INSTRUCTIONS,7 
	.DB	RANDOM
	.DRW	DUD09
	.DB	127
	.DB	GOTO,69,-1
	.DB	SETMOM,2,0
	.DB	ANIMATION,15,RESERVE
DUD8A:	.DB	MOVEIN,2,0
	.DB	RANDOM
	.DRW	DUD8A
	.DB	240	
	.DB	ACTIVATE,EFALL

DUD09:	.DB	GOTO,179,-1
	.DB	SETMOM,-2,0
	.DB	ANIMATION,15,RESERVE
DUD9A:	.DB	MOVEIN,2,0
	.DB	RANDOM
	.DRW	DUD9A
	.DB	240	
	.DB	ACTIVATE,EFALL


DFALL: 
	.DB	GRAVITY,0
	.DB	SOLIDSTATE,OFF 
	.DB	MOMLIMIT,40,64		

;CODE TO MAKE DIFFERENT PICTURES WHEN FALLING!!	

	.DB	INSTRUCTIONS,5
	.DB	FETCHREG,RANDOM
	.DB	ANDREG
	.DRW	H'03
	.DB	CASE
	.DRW	PIC1,0
	.DRW	PIC2,1
	.DRW	PIC3,2
	.DRW	PIC2,3
	.DRW	0
PIC1:	.DB	ANIMATION,3,RESERVE
	.DB	SKIP
	.DRW	DUD10
PIC2:	.DB	ANIMATION,6,RESERVE
	.DB	SKIP
	.DRW	DUD10
PIC3:	.DB	ANIMATION,9,RESERVE

DUD10:	.DB	DELAY,1
DUD10A:	.DB	SETMOM,0,24 
	.DB	YVISUAL
	.DRW	DUD10A
	.DB	208   

DUD20:	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,12,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    

DHURT: 

DHURT10:			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	DHURT20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0
			   
DHURT20:		  		;BOUNCE OFF HAND
	.DB	ANIMATION,6,RESERVE
	.DB	NOISE
	.DRW	TRXSND
	.DB	SETMOM,0,-8
	.DB	DELAY,13
DHURT25:.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	DHURT25
	.DB	208   
	.DB	SKIP
	.DRW	DUD20


;-------------------------------------------
	.DRW	MANS2
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MANWALK 	    
	.DB	0
DUDER2:	.DRW	DUMMY,D2CODE
	.DB	0,-1,0,H'00,0
	.DRW	-1,D2HURT
	.DB	H'40,-1,0,0,0

D2CODE:
	.DB	IDENTIFY
	.DRW	KILLER
	.DB	SOLIDSTATE,ON
	.DB	ENABLE,HURTING

D2C1:	.DB	RANDOM			;DETERMINE LOCATION
	.DRW	D2C2
	.DB	127
	.DB	GOTO,69,-1
	.DB	ANIMATION,3,RESERVE
	.DB	SKIP
	.DRW	D2C10

D2C2:	.DB	GOTO,179,-1
D2C11:	.DB	ANIMATION,3,RESERVE
	.DB	GRAVITY,-1

D2C10:	.DB	RANDOM		;DETERMINE DIRECTION
	.DRW	D2C4
	.DB	127	
D2C3:	.DB	NOTSTANDING
	.DRW	D2C15 
	.DB	SETMOM,8,0
	.DB	TESTSOLID
	.DRW	D2C4
	.DB	3,0
	.DB	SKIP
	.DRW	D2C3
D2C4:	.DB	NOTSTANDING
	.DRW	D2C15 
	.DB	SETMOM,-8,0
	.DB	TESTSOLID
	.DRW	D2C3
	.DB	-3,0
	.DB	SKIP
	.DRW	D2C4



D2C15:
 	.DB	GRAVITY,0
	.DB	FACE,TRAVELING
	.DB	ANIMATION,9,RESERVE
D2C16: 	.DB	STANDING      		;FALLING CODE
	.DRW	D2C11
	.DB	SETMOM,0,24
	.DB	YVISUAL				;HE FELL INTO ACID
	.DRW	D2C16
	.DB	208


D2C20: 	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,6,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    

	
D2HURT: 

D2H10:			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D2H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0

D2H20: 	.DB	ANIMATION,12,RESERVE
	.DB	NOISE
	.DRW	TRXSND
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D2H25:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D2H25
	.DB	208   
	.DB	SKIP
	.DRW	D2C20


;-----------------------------------------

	.DRW	MANS1
	.DB	0
	.DRW	MANS3
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MANTWRL
	.DB	0
DUDER3:	.DRW	DUMMY,D3CODE
	.DB	0,-1,0,0,0
	.DRW	-1,D3HURT
	.DB	H'40,-1,0,0,0	

D3CODE:
	.DB	GRAVITY,0
	.DB	IDENTIFY
	.DRW	KILLER
	.DB	ENABLE,HURTING
	.DB	SOLIDSTATE,ON
	.DB	BOUNCE,200
	.DB	RANDOM
	.DRW	D3C10
	.DB	127
	.DB	GOTO,85,-1  
	.DB	LAUNCH,10,0,0,0
	.DB	ANIMATION,3,RESERVE	
	.DB	LOWNOISE
	.DRW	THUNSND
D3C5:  	.DB	INSTRUCTIONS,3	    	
	.DB	YVISUAL				;SHOOT 'EM!!
	.DRW	D3C30
	.DB	48 
	.DB	SETMOM,40,-8
	.DB	RANDOM
	.DRW	D3C30
	.DB	10  
	.DB	TESTSOLID      
	.DRW	D3C15	
	.DB	3,0
	.DB	SKIP
	.DRW	D3C5	


D3C10:	.DB	GOTO,156,-1	
	.DB	LAUNCH,10,0,0,0
	.DB	ANIMATION,3,RESERVE	
	.DB	LOWNOISE
	.DRW	THUNSND
D3C15:	.DB	INSTRUCTIONS,3
	.DB	YVISUAL		       		;SHOOT 'EM!!
	.DRW	D3C30
	.DB	48 
	.DB	SETMOM,-40,-8
	.DB	RANDOM
	.DRW	D3C30
	.DB	10
 	.DB	TESTSOLID      
	.DRW	D3C5	
	.DB	-3,0
	.DB	SKIP
	.DRW	D3C15	


D3C30:	.DB	ANIMATION,12,RESERVE
	.DB	GRAVITY,-1 
	.DB	MOMLIMIT,8,24	  	;HE'S FALLING NOW
D3C31:	.DB	YVISUAL
	.DRW	D3C31
	.DB	208
	


D3C20: 	.DB	GRAVITY,0
	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,6,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    



D3HURT: 
D3H10:			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D3H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0

D3H20: 	.DB	ANIMATION,9,RESERVE	 ;BOUNCE OFF THE HAND
	.DB	NOISE
	.DRW	TRXSND
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D3H25:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D3H25
	.DB	208   
	.DB	SKIP
	.DRW	D3C20

;--------------------------------------------------
	.DRW	MANS3
	.DB	0
	.DRW	MANS4
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MANS1
	.DB	0
DUDER4:	.DRW	CLIMBER,DUD4CODE
	.DB	0,-1,H'30,0,H'11
	.DRW	-1,D4HURT
	.DB	0,-1,0,0,0

DUD4CODE:
	.DB	GRAVITY,0
	.DB	ENABLE,HURTING
	.DB	SOLIDSTATE,OFF
	.DB	IDENTIFY
	.DRW	HELPER
D4C10:	.DB	SETMOM,0,8
	.DB	YVISUAL
	.DRW	D4C10
	.DB	160 	
	.DB	ANIMATION,3,RESERVE
	.DB	SKIP
	.DRW	D4H5

D4C20: 	.DB	GRAVITY,0
	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,6,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    


D4HURT:	.DB	ATTACKER	;HIT BY BULLET
	.DRW	CLMBHURT 
	.DB	12  
	
	.DB	SETMOM,0,0     	;CAUGHT SAFELY IN HAND
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D4H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0

CLMBHURT:
	.DB	INSTRUCTIONS,18
;CODE TO MAKE DIFFERENT PICTURES WHEN FALLING!!	

	.DB	RANDOM	 	    	
	.DRW	D4H11
	.DB	127
	.DB	ANIMATION,3,RESERVE
	.DB	SKIP
	.DRW	D4H13
D4H11: 	.DB	RANDOM	 	    	
	.DRW	D4H12
	.DB	127
	.DB	ANIMATION,9,RESERVE
	.DB	SKIP
	.DRW	D4H13
D4H12: 	.DB	ANIMATION,12,RESERVE
D4H13:	.DB	IDENTIFY
	.DRW	KILLER
	.DB	ENABLE,HURTING
	.DB	THROWBACK,72,-32
	.DB	THROWBACK,72,-32
	.DB	THROWBACK,72,-32
	.DB	RANDOM
	.DRW	D4H5
	.DB	127
	.DB	THROWBACK,72,-32 
	.DB	THROWBACK,72,-32
	.DB	THROWBACK,72,-32
	.DB	RANDOM
	.DRW	D4H5
	.DB	127
	.DB	THROWBACK,72,-32
	.DB	THROWBACK,72,-32 
	.DB	THROWBACK,72,-32 
D4H5: 	.DB	IDENTIFY
	.DRW	KILLER
D4H6:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D4H6
	.DB	208	
	.DB	SKIP
	.DRW	D4C20

D4H20: 	.DB	ANIMATION,12,RESERVE	 ;BOUNCE OFF THE HAND
	.DB	NOISE
	.DRW	TRXSND
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D4H25:	.DB	SETMOM,0,16
	.DB	YVISUAL
	.DRW	D4H25
	.DB	208   
	.DB	SKIP
	.DRW	D4C20

;-------------------------PARACHUTE WORLD
	.DRW	MANS3
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MANCHUTE
	.DB	0
DUDER5:	.DRW	DUMMY,DUD5CODE
	.DB	0,-1,0,0,0
	.DRW	-1,D5HURT
	.DB	0,-1,0,0,0
	
DUD5CODE:
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	IDENTIFY
	.DRW	KILLER
	.DB	ENABLE,HURTING

D5C5:	.DB	FETCHREG,RANDOM	 	;LOCATION CODE	
	.DB	COMPARE
	.DRW	D5C6
	.DRW	69
	.DB	SKIP
	.DRW	D5C5
D5C6:	.DB	COMPARE
	.DRW	D5C5
	.DRW	180

D5C10:	.DB	GOTO,REGISTER,-1
	.DB	ANIMATION,3,RESERVE
	.DB	RANDOM	 		;GO RIGHT OR LEFT?
	.DRW	D5C18
	.DB	127

D5C11:	.DB	RANDOM
	.DRW	D5C15
	.DB	127

D5C12:	.DB	SETMOM,16,8    		;MOVE FAST RIGHT
	.DB	TESTSOLID
	.DRW	D5C18
	.DB	3,0
	.DB	YVISUAL
	.DRW	D5C12
	.DB	208
	.DB	SKIP
	.DRW	D5C30
D5C15:	.DB	SETMOM,8,16	    	;MOVE SLOW RIGHT
	.DB	TESTSOLID
	.DRW	D5C18
	.DB	3,0
	.DB	YVISUAL
	.DRW	D5C15
	.DB	208
	.DB	SKIP
	.DRW	D5C30
		

D5C18: 	.DB	RANDOM
	.DRW	D5C25
	.DB	127

D5C20:	.DB	SETMOM,-16,8		;MOVE FAST LEFT		
	.DB	TESTSOLID
	.DRW	D5C11
	.DB	-3,0
	.DB	YVISUAL
	.DRW	D5C20
	.DB	208
	.DB 	SKIP
	.DRW	D5C30
D5C25:	.DB	SETMOM,-8,16		;MOVE SLOW LEFT		
	.DB	TESTSOLID
	.DRW	D5C11
	.DB	-3,0
	.DB	YVISUAL
	.DRW	D5C25
	.DB	208
	
D5C30: 	.DB	GRAVITY,0
	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,6,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    

D5HURT: 
D5H10:			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D5H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0

D5H20: 	.DB	ANIMATION,9,RESERVE	 ;BOUNCE OFF THE HAND
	.DB	NOISE
	.DRW	TRXSND
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D5H25:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D5H25
	.DB	208   
	.DB	SKIP
	.DRW	D5C30

;----------------------------------------------------
	.DRW	MANS4
	.DB	0
	.DRW	MANS3
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MANS1
	.DB	0
DUDER6:	.DRW	DUMMY,DUD6CODE
	.DB	0,-1,0,0,0
	.DRW	-1,D6HURT
	.DB	0,-1,0,0,0
	.DRW	-1,D6FALL
	.DB	0,-1,0,0,0

DUD6CODE:
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	IDENTIFY
	.DRW	HELPER
	.DB	ADDIDENTIFY
	.DRW	KILLER
	.DB	BOUNCE,200

	.DB	FETCHREG,WORLD	       	;SHARED BETWEEN 6,9,10,11
	.DB	CASE			;PLATFORMS,MOUTH,FIRE,TRASH
	.DRW	D6C15A,6
	.DRW	D6C15A,11
	.DRW	0

D6C10:	.DB	FETCHREG,RANDOM	 	;LOCATION CODE	
	.DB	COMPARE
	.DRW	D6C15
	.DRW	69
	.DB	SKIP
	.DRW	D6C10
D6C15:	.DB	COMPARE
	.DRW	D6C10
	.DRW	180

	.DB	GOTO,REGISTER,-1
D6C15A:
	.DB	RANDOM
	.DRW	D6C15B
	.DB	127
	.DB	ANIMATION,3,RESERVE	       	;FALL FROM MOUTH/CAN
	.DB	SKIP
	.DRW	D6FALL
D6C15B:	.DB	RANDOM
	.DRW	D6C15C
	.DB	127
	.DB	ANIMATION,9,RESERVE	       	;FALL FROM MOUTH/CAN
	.DB	SKIP
	.DRW	D6FALL
D6C15C:	.DB	ANIMATION,12,RESERVE	       	;FALL FROM MOUTH/CAN
D6FALL:	.DB	ENABLE,HURTING
D6C16:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D6C16
	.DB	208

D6C20: 	.DB	GRAVITY,0
	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,6,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    

D6HURT:
	.DB	ATTACKER			
	.DRW	D6H10
	.DB	1

	.DB	THROWBACK,64,-32 	 
	.DB	THROWBACK,64,-32 	 
	.DB	THROWBACK,64,-32 	 
	.DB	THROWBACK,64,-32
	.DB	THROWBACK,64,-32
	.DB	RANDOM
	.DRW	D6H5
	.DB	127	
	.DB	THROWBACK,64,-32
	.DB	THROWBACK,64,-32
	.DB	THROWBACK,64,-32
	.DB	THROWBACK,64,-32
	.DB	THROWBACK,64,-32
D6H5:	.DB	ACTIVATE,EFALL

D6H10:			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D6H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0

D6H20: 
	.DB	ANIMATION,9,RESERVE	 ;BOUNCE OFF THE HAND
	.DB	NOISE
	.DRW	TRXSND
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D6H25:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D6H25
	.DB	208   
	.DB	SKIP
	.DRW	D6C20
;-----------------------------------------------------------
	.DRW	MANS4 	;21
	.DB	0
	.DRW	MANS3
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MANS1
	.DB	0
	.DRW	BUB4
	.DB	0
	.DRW	BUBS
	.DB	0
	.DRW	BUB5
	.DB	0
DUDER7:	.DRW	DUMMY,DUD7CODE
	.DB	0,-1,0,0,0
	.DRW	-1,D7HURT
	.DB	0,-1,0,0,0

DUD7CODE:
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	IDENTIFY
	.DRW	HELPER
	.DB	ADDIDENTIFY
	.DRW	KILLER

	.DB	RANDOM	
	.DRW	DC710
	.DB	127
	.DB	GOTO,81,155 		;LAUNCH ON LEFT
	.DB	SKIP
	.DRW	DC715

DC710:	.DB	GOTO,167,155 		;LAUNCH ON RIGHT

DC715:	.DB	ANIMATION,3,RESERVE	;PEEK OUT OF PIPE	
	.DB	DELAY,4
	.DB	ANIMATION,6,RESERVE	;COME OUT

DC716:	.DB	YVISUAL
	.DRW	DC730
	.DB	56
	.DB	SETMOM,-1,-8
	.DB	RANDOM
	.DRW	DC720
	.DB	127
	.DB	SETMOM,-16,-1
	.DB	SKIP
	.DRW	DC716
DC720:	.DB	SETMOM,16,-1 
	.DB	SKIP
	.DRW	DC716	

DC730:	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	POPSND
	.DB	ANIMATION,9,RESERVE	;POP!
	.DB	DELAY,1
	.DB	ENABLE,HURTING		;NOW FALL

	.DB	RANDOM
	.DRW	DC733
	.DB	127
	.DB	ANIMATION,18,RESERVE
	.DB	SKIP
	.DRW	DC735
DC733:	.DB	RANDOM
	.DRW	DC734
	.DB	127
	.DB	ANIMATION,12,RESERVE
	.DB	SKIP
	.DRW	DC735
DC734:	.DB	ANIMATION,21,RESERVE

DC735:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	DC735
	.DB	208

D7C40: 	.DB	GRAVITY,0
	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,15,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    


D7HURT:
D7H10:			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D7H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0

D7H20: 
	.DB	ANIMATION,18,RESERVE	 ;BOUNCE OFF THE HAND
	.DB	NOISE
	.DRW	TRXSND
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D7H25:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D7H25
	.DB	208   
	.DB	SKIP
	.DRW	D7C40

;----------------------------------------------------------

	.DRW	ZAPS1
	.DB	0
	.DRW	MANS3
	.DB	0
	.DRW	MANWALK 	    
	.DB	0
DUDER8:	.DRW	DUMMY,DUD8CODE
	.DB	0,-1,0,H'00,0
	.DRW	-1,D8HURT
	.DB	H'40,-1,0,0,0
	.DRW	DUMMY,D8FALL   
	.DB	H'40,-2,0,0,0

DUD8CODE:
	.DB	GRAVITY,-1		       ;WALKING CODE
	.DB	MOMLIMIT,8,1
	.DB	FRICTION,0,0
D8C8: 
	.DB	RANDOM
	.DRW	D8C9
	.DB	127
	.DB	GOTO,69,-1
	.DB	SETMOM,2,0
	.DB	ANIMATION,3,RESERVE
	.DB	DISPLAY,BEHIND

D8C8A:	.DB	MOVEIN,2,0
	.DB	RANDOM
	.DRW	D8C8A
	.DB	240	
	.DB	ACTIVATE,EFALL

D8C9:	.DB	GOTO,179,-1
	.DB	SETMOM,-2,0
	.DB	ANIMATION,3,RESERVE
D8C9A:	.DB	MOVEIN,2,0
	.DB	RANDOM
	.DRW	D8C9A
	.DB	240	
	.DB	ACTIVATE,EFALL


D8FALL: 
	.DB	GRAVITY,0
	.DB	IDENTIFY
	.DRW	KILLER
	.DB	ENABLE,HURTING      
	.DB	SOLIDSTATE,OFF 
	.DB	MOMLIMIT,40,64		
	.DB	TARGET 			;TARGET NOBODY
	.DRW	BENIGN	    
	       
	.DB	ANIMATION,6,RESERVE	

D8C40:	.DB	DELAY,1
	.DB	SETMOM,0,40

D8C40A:	.DB	INSTRUCTIONS,4
	.DB	LAUNCH,25,5,0,0		;LAUNCH CORD
	.DB	SETMOM,0,24    		;CODE TO GO DOWN
	.DB	DELAY,2
	.DB	YVISUAL
	.DRW	D8C40A
	.DB	176   

	.DB	SETMOM,0,0
	.DB	DELAY,7
	.DB	TARGET
	.DRW	HARMLESS
D8C45:	.DB	SETMOM,0,-32
	.DB	YVISUAL
	.DRW	D8C50
	.DB	64
	.DB	SKIP
	.DRW	D8C45
D8C50:	.DB	SETMOM,0,-40
	.DB	YVISUAL	
	.DRW	D8C20
 	.DB	48
	.DB	SKIP
	.DRW	D8C50


D8C20:	.DB	SETMOM,0,0		;HE HIT THE WALL 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,9,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    



D8HURT: 
D8H10: 			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D8H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0
			   
D8H20:	.DB	NOISE
	.DRW	TRXSND
	.DB	SKIP
	.DRW	D8C45

;------------------------------------------------------------------
	.DRW	MANS4
	.DB	0
	.DRW	MANS3
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MANS1
	.DB	0
DUDER9:	.DRW	DUMMY,DUD9CODE
	.DB	0,-1,0,0,0
	.DRW	-1,D9HURT
	.DB	0,-1,0,0,0
	.DRW	-1,D9FALL
	.DB	0,-1,0,0,0

DUD9CODE:
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	BOUNCE,200					     

	.DB	IDENTIFY
	.DRW	HELPER
	.DB	ADDIDENTIFY
	.DRW	KILLER

D9C10:	.DB	FETCHREG,RANDOM	 	;LOCATION CODE	
	.DB	COMPARE
	.DRW	D9C15
	.DRW	69
	.DB	SKIP
	.DRW	D9C10
D9C15:	.DB	COMPARE
	.DRW	D9C10
	.DRW	179

	.DB	GOTO,REGISTER,-1
	.DB	RANDOM
	.DRW	D9C15A
	.DB	127
	.DB	ANIMATION,3,RESERVE
	.DB	SKIP
	.DRW	D9C15B

D9C15A:	.DB	ANIMATION,12,RESERVE	       	
D9C15B:	.DB	ENABLE,HURTING
	.DB	SOLIDSTATE,OFF
	
D9C16:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D9C16
	.DB	208

D9C20: 	.DB	GRAVITY,0
	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,6,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    

D9FALL:	.DB	ENABLE,HURTING
	.DB	SETMOM,-1,24
D9F25:	.DB	YVISUAL
	.DRW	D9F25
	.DB	208
	.DB	SKIP
	.DRW	D9C20

D9HURT:	.DB	SOLIDSTATE,ON
	.DB	ATTACKER			
	.DRW	D9H10
	.DB	1

	.DB	ENABLE,HURTING
	.DB	RANDOM
	.DRW	D9H5				;GO UP OR DOWN?
	.DB	127

D9H3:	.DB	RANDOM
	.DRW	D9H4				
	.DB	127

	.DB	SETMOM,64,-64		;UP AND RIGHT
	.DB	SETMOM,64,-64
	.DB	SETMOM,64,-64
	.DB	SETMOM,64,-64
	.DB	ACTIVATE,EFALL

D9H4:	.DB	SETMOM,-64,-64	     	;UP AND LEFT
	.DB	SETMOM,-64,-64
	.DB	SETMOM,-64,-64
	.DB	SETMOM,-64,-64
	.DB	ACTIVATE,EFALL

D9H5:	.DB	RANDOM	      	    
	.DRW	D9H6
	.DB	127

	.DB	SETMOM,64,-1 			;DOWN AND RIGHT
	.DB	SETMOM,64,-1
	.DB	SETMOM,64,-1
	.DB	SETMOM,64,-1
	.DB	ACTIVATE,EFALL

D9H6: 	.DB	SETMOM,-64,-1 			;DOWN AND LEFT
	.DB	SETMOM,-64,-1
	.DB	SETMOM,-64,-1
	.DB	SETMOM,-64,-1
	.DB	ACTIVATE,EFALL

D9H10:			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D9H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0

D9H20: 
	.DB	ANIMATION,9,RESERVE	 ;BOUNCE OFF THE HAND
	.DB	NOISE
	.DRW	TRXSND
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D9H25:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D9H25
	.DB	208   
	.DB	SKIP
	.DRW	D9C20
;---------------------------------------------
	.DRW	MANS4
	.DB	
	.DRW	ZAPS1
	.DB	
	.DRW	MANS3
	.DB	
	.DRW	MAN7
	.DB	
	.DRW	MANS1
	.DB	
DUDER10:.DRW	DUMMY,D10CODE
	.DB	0,-1,0,0,0
	.DRW	-1,D10HURT
	.DB	0,-1,0,0,0

D10CODE:
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	SOLIDSTATE,ON
	.DB	BOUNCE,250
	.DB	IDENTIFY
	.DRW	HELPER
	.DB	ADDIDENTIFY
	.DRW	KILLER		  	
	.DB	MOMLIMIT,72,72
	.DB	ENABLE,HURTING
	.DB	FETCHREG,RANDOM
	.DB	ANDREG
	.DRW	H'03
	.DB	CASE
	.DRW	DC105,0
	.DRW	DC106,1
	.DRW	DC107,2
	.DRW	DC108,3
	.DRW	0

DC105:	.DB	ANIMATION,3,RESERVE
	.DB	SKIP
	.DRW	DC109

DC106:	.DB	ANIMATION,3,RESERVE
	.DB	SKIP
	.DRW	DC109

DC107:	.DB	ANIMATION,9,RESERVE
	.DB	SKIP
	.DRW	DC109

DC108:	.DB	ANIMATION,15,RESERVE

DC109:	.DB	FETCHREG,PARAM2
	.DB	CASE
	.DRW	DC1010,1
	.DRW	DC1020,2
	.DRW	DC1030,3
	.DRW	DC1040,4
	.DRW	0

DC1010:
	.DB	SETMOM,0,-32		;UP			
	.DB	DELAY,10			
	.DB	SETMOM,0,0
	.DB	DELAY,60
	.DB	SKIP
	.DRW	DC1050	

DC1020:
	.DB	SETMOM,32,0		;RIGHT				
	.DB	DELAY,10			
	.DB	SETMOM,0,0
	.DB	DELAY,40
	.DB	SKIP
	.DRW	DC1050	

DC1030:
	.DB	SETMOM,0,32		;DOWN				
	.DB	DELAY,10			
	.DB	SETMOM,0,0
	.DB	DELAY,20
	.DB	SKIP
	.DRW	DC1050	

DC1040:
	.DB	SETMOM,-32,0		;LEFT			
	.DB	DELAY,10			
	.DB	SETMOM,0,0
	.DB	DELAY,70

DC1050:	.DB	SETMOM,-1,32
	.DB	YVISUAL
	.DRW	DC1050
	.DB	200

DC1070:	.DB	INSTRUCTIONS,7
	.DB	SETMOM,0,0		;HE HIT THE WALL 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,12,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    


D10HURT: 
D10H10: 			       	;CAUGHT SAFELY IN HAND
	.DB	INSTRUCTIONS,8
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D10H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0
			   
D10H20:
	.DB	INSTRUCTIONS,8
	.DB	NOISE
	.DRW	TRXSND
	.DB	ANIMATION,3,RESERVE
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D10H25:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D10H25
	.DB	208   
	.DB	SKIP
	.DRW	DC1070

;-----------------------------------------
	.DRW	MANS1
	.DB	0
	.DRW	MANS3
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MANTWRL
	.DB	0
DUDER11:.DRW	DUMMY,D11CODE
	.DB	0,-1,0,0,0
	.DRW	-1,D11HURT
	.DB	H'40,-1,0,0,0	

D11CODE:
	.DB	GRAVITY,0
	.DB	IDENTIFY
	.DRW	KILLER
	.DB	ENABLE,HURTING
	.DB	SOLIDSTATE,ON
	.DB	BOUNCE,200
	.DB	RANDOM
	.DRW	D11C10
	.DB	127


;CODE FOR LEFT SIDE

	.DB	RANDOM
	.DRW	D11C1
	.DB	127	
	.DB	GOTO,64,80 
	.DB	NOISE
	.DRW	HRN1SND
	.DB	SKIP
	.DRW	D11C5 	       		
D11C1:	.DB	RANDOM
	.DRW	D11C2
	.DB	127	
	.DB	GOTO,64,112 	       		
	.DB	NOISE
	.DRW	HRN6SND
	.DB	SKIP
	.DRW	D11C5 	       		
D11C2:	.DB	GOTO,64,144 	       		
	.DB	NOISE
	.DRW	HRN5SND

D11C5:
	.DB	ANIMATION,3,RESERVE	
 	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	RANDOM
	.DRW	D11C30
	.DB	127
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	RANDOM
	.DRW	D11C30
	.DB	127
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SETMOM,32,-1
	.DB	SKIP
	.DRW	D11C30	


;CODE FOR RIGHT SIDE

D11C10:	.DB	RANDOM
	.DRW	D11C11
	.DB	127	
	.DB	GOTO,184,80 
	.DB	NOISE
	.DRW	HRN4SND
	.DB	SKIP
	.DRW	D11C15 	       		
D11C11:	.DB	RANDOM
	.DRW	D11C12
	.DB	127	
	.DB	GOTO,184,112	       		
	.DB	NOISE
	.DRW	HRN2SND
	.DB	SKIP
	.DRW	D11C15 	       		
D11C12:	.DB	GOTO,184,144 	       		
	.DB	NOISE
	.DRW	HRN3SND

D11C15:	.DB	ANIMATION,3,RESERVE	
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	RANDOM
	.DRW	D11C30
	.DB	127
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	RANDOM
	.DRW	D11C30
	.DB	127
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1
	.DB	SETMOM,-32,-1

D11C30:	.DB	GRAVITY,-1 
	.DB	MOMLIMIT,8,24	  	;HE'S FALLING NOW
	.DB	ANIMATION,12,RESERVE
D11C31:	.DB	YVISUAL
	.DRW	D11C31
	.DB	208
	


D11C20: .DB	GRAVITY,0
	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,6,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    



D11HURT: 
D11H10:			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D11H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0

D11H20: .DB	ANIMATION,9,RESERVE	 ;BOUNCE OFF THE HAND
	.DB	NOISE
	.DRW	TRXSND
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D11H25:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D11H25
	.DB	208   
	.DB	SKIP
	.DRW	D11C20


;---------------------------------------------------------------------
	.DRW	MANS3
	.DB	0
	.DRW	ZAPS1
	.DB	0
	.DRW	MANS1
	.DB	0
	.DRW	MANTWRL
	.DB	0
DUDER12:.DRW	DUMMY,D12CODE
	.DB	0,-1,0,0,0
	.DRW	-1,D12HURT
	.DB	H'40,-1,0,0,0	

D12CODE:
	.DB	GRAVITY,0
	.DB	IDENTIFY
	.DRW	KILLER
	.DB	BOUNCE,250
	.DB	ENABLE,HURTING
	.DB	SOLIDSTATE,ON
	
D12C10:	.DB	FETCHREG,RANDOM
	.DB	COMPARE
	.DRW	D12C10
	.DRW	176		;160
	.DB	COMPARE
	.DRW	D12C11
	.DRW	88
	.DB	SKIP
	.DRW	D12C10	
	
D12C11:	.DB	GOTO,REGISTER,94
	.DB	ANIMATION,3,RESERVE
	.DB	NOISE
	.DRW	POPCSND
	.DB	RANDOM
	.DRW	D12C12
	.DB	127
	
	.DB	SETMOM,-24,-40 		;UP AND LEFT
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	RANDOM
	.DRW	D12C30
	.DB	127
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	SKIP
	.DRW	D12C30

D12C12:	.DB	RANDOM
	.DRW	D12C13
	.DB	127
	.DB	SETMOM,0,-40 		;STRAIGHT UP
	.DB	SETMOM,0,-40
	.DB	SETMOM,0,-40
	.DB	SETMOM,0,-40
	.DB	RANDOM
	.DRW	D12C30
	.DB	127
	.DB	SETMOM,0,-40
	.DB	SETMOM,0,-40
	.DB	SETMOM,0,-40
	.DB	SKIP
	.DRW	D12C30
		
D12C13:	.DB	SETMOM,24,-40 		;UP AND RIGHT
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40
	.DB	RANDOM
	.DRW	D12C30
	.DB	127
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40

D12C30:	.DB	SETMOM,-1,24
	.DB	MOMLIMIT,-1,24	  	;HE'S FALLING NOW
	.DB	ANIMATION,6,RESERVE
D12C31:	.DB	YVISUAL
	.DRW	D12C31
	.DB	208
	
D12C20: .DB	GRAVITY,0
	.DB	SETMOM,0,0		;HE HIT THE ACID 
	.DB	ADDSCORE,JOY1
	.DRW	-5
	.DB	SHOWSCORE,JOY1,16,1,0
;	.DB	LOAD,24			;ADD TO DEATH COUNTER
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,24
	.DB	ANIMATION,9,RESERVE
	.DB	NOISE
	.DRW	FALSND
	.DB	DELAY,8      
	.DB	DIE,0	    

D12HURT: 
D12H10:			       	;CAUGHT SAFELY IN HAND
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	GOTPRIZE
	.DB	LOAD,50
	.DB	ADD
	.DRW	1
	.DB	COMPARE
	.DRW	D12H20
	.DRW	16
	.DB	STORE,50
	.DB	SHOWREG,20,1,0
	.DB	DIE,0

D12H20: .DB	ANIMATION,12,RESERVE	 ;BOUNCE OFF THE HAND
	.DB	NOISE
	.DRW	TRXSND
	.DB	GRAVITY,0
	.DB	SETMOM,0,-8
	.DB	DELAY,13
D12H25:	.DB	SETMOM,0,24
	.DB	YVISUAL
	.DRW	D12H25
	.DB	208   
	.DB	SKIP
	.DRW	D12C20


;--------------------------------------------------------------
FOOTY:	.DRW	FOOT,FOOTCODE
	.DB	0,-2,0,0,0

FOOTCODE:
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	TARGET
	.DRW	HERO0

FOOT10:	.DB	RANDOM
	.DRW	FOOT11
	.DB	20
	.DB	SETMOM,16,0
	.DB	TESTSOLID
	.DRW	FOOT20
	.DB	3,0
	.DB	SKIP
	.DRW	FOOT10
FOOT11:	.DB	SETMOM,0,40
	.DB	YVISUAL
	.DRW	FOOT11
	.DB	192
FOOT12:	.DB	SETMOM,0,-40
	.DB	YVISUAL
	.DRW	FOOT10
	.DB	120 
	.DB	SKIP
	.DRW	FOOT12		

FOOT20:	.DB	RANDOM
	.DRW	FOOT21
	.DB	20
	.DB	SETMOM,-16,0    
	.DB	TESTSOLID
	.DRW	FOOT10
	.DB	-3,0
	.DB	SKIP
	.DRW	FOOT20	
FOOT21:	.DB	SETMOM,0,40
	.DB	YVISUAL
	.DRW	FOOT21
	.DB	192
FOOT22:	.DB	SETMOM,0,-40
	.DB	YVISUAL
	.DRW	FOOT20
	.DB	120 
	.DB	SKIP
	.DRW	FOOT22		

;----------------------------------------------------------------

CORDY:
	.DRW	CORD,CORDCODE
	.DB	0,-1,0,0,0
	.DRW	-1,CORDHURT
	.DB	0,-1,0,0,0

CORDCODE:
	.DB	INSTRUCTIONS,4
	.DB	GRAVITY,0
	.DB	IDENTIFY
	.DRW	HARMLESS
CORD11:	.DB	ENABLE,HURTING
CORD10:	.DB	ACTIVE
	.DRW	CORD10
	.DB	ID
	.DRW	26 		;IF GUY DEAD THEN DIE TOO
	.DB	DIE,0

CORDHURT:
	.DB	ATTACKER
	.DRW	CORD11
	.DB	1
	.DB	DIE,0


;----------------------------------------------
	.DRW	MOUTH3
	.DB	0
	.DRW	MOUTH2
	.DB	0
MOUTHY:	.DRW	MOUTH1,MTHCODE
	.DB	0,-1,0,0,0

MTHCODE:.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	SOLIDSTATE,ON

MTH5:	.DB	YVISUAL
	.DRW	MTH6
	.DB	144 
	.DB	SETMOM,-1,-40
	.DB	SKIP
	.DRW	MTH5	
	
MTH6:	.DB	YVISUAL
	.DRW	MTH6A
	.DB	104 
	.DB	SKIP
	.DRW	MTH6B
MTH6A:	.DB	SETMOM,-1,40
	.DB	SKIP
	.DRW	MTH6

MTH6B:	.DB	RANDOM
	.DRW	MTH7
	.DB	160
	.DB	SETMOM,0,0
	.DB	ANIMATION,3,RESERVE

MTH6BA:	.DB	RANDOM
	.DRW	MTH6C
	.DB	60
	
	.DB	LAUNCH,19,16,12,0		;SPIT OUT DUDES		  
	.DB	DELAY,11
	.DB	SKIP
	.DRW	MTH7

MTH6C: 	.DB	RANDOM
	.DRW	MTH6D
	.DB	127

	.DB	SETMOM,0,0
	.DB	ANIMATION,6,RESERVE
	.DB	SOUND
	.DRW	-1,-1,-1,SPTSNDA  
	.DB	SOUND
	.DRW	-1,-1,-1,SPTSNDB  
	.DB	LAUNCH,34,8,12,0		;SPIT OUT VOMIT		  
	.DB	DELAY,11
	.DB	SKIP
	.DRW	MTH7


MTH6D:
	.DB	LAUNCH,7,0,0,0		;LAUNCH DUCKS
	.DB	SKIP
	.DRW	MTH6BA 

MTH7:	.DB	ANIMATION,EWAKE,2
	.DB	STANDING
	.DRW	MTH90
	.DB	DELAY,5
	.DB	RANDOM
	.DRW	MTH45
	.DB	127

	.DB	INSTRUCTIONS,5
	.DB	FETCHREG,RANDOM
	.DB	ANDREG
	.DRW	H'03
	.DB	CASE
	.DRW	MTH10,0
	.DRW	MTH20,1
	.DRW	MTH30,2
	.DRW	MTH40,3
	.DRW	0


MTH10: 	.DB	SETMOM,0,-24		;NORTH
	.DB	SKIP
	.DRW	MTH5			

MTH20:	.DB	SETMOM,-24,-24		;NORTH WEST
	.DB	SKIP
	.DRW	MTH5			

MTH30:	.DB	SETMOM,-24,0		;WEST
	.DB	SKIP
	.DRW	MTH5			

MTH40:	.DB	SETMOM,-24,24		;SOUTH WEST
	.DB	SKIP
	.DRW	MTH5			


MTH45:	.DB	INSTRUCTIONS,5	
	.DB	FETCHREG,RANDOM
	.DB	ANDREG
	.DRW	H'03
	.DB	CASE
	.DRW	MTH50,0
	.DRW	MTH60,1
	.DRW	MTH70,2
	.DRW	MTH80,3
	.DRW	0


MTH50:	.DB	SETMOM,0,24		;SOUTH
	.DB	SKIP
	.DRW	MTH5			

MTH60:	.DB	SETMOM,24,24		;SOUTH EAST
	.DB	SKIP
	.DRW	MTH5			

MTH70:	.DB	SETMOM,24,0		;EAST
	.DB	SKIP
	.DRW	MTH5			

MTH80:	.DB	SETMOM,24,-24		;NORTH EAST
	.DB	SKIP
	.DRW	MTH5			

MTH90:	.DB	REVMOM,CHANGE,CHANGE
	.DB	SKIP
	.DRW	MTH5


;-----------------------------------------------------------------------

MESSAGE:
	.DRW	DUMMY,MESCODE
	.DB	0,-1,0,0,0

MESCODE:
	.DB	GRAVITY,0
	.DB	SETPAUSE,OFF
	.DB	LOAD,60
	.DB	EQUAL
	.DRW	MES5
	.DRW	0	
	.DB	SOUND
	.DRW	0,0,STUBASS,GUTDRUM
MES5:	.DB	LOAD,57
	.DB	CASE
	.DRW	MES10,1 ;I-BEAM
	.DRW	MES20,2	;PARACHUTE
	.DRW	MES30,3	;PIPES
	.DRW	MES40,4	;SNIPER
	.DRW	MES50,5	;JUNGLE
	.DRW	MES60,6	;MOUTH
	.DRW	MES70,7	;CANNONS
	.DRW	MES80,8	;FIRE
	.DRW	MES90,9	;BUNGEE
	.DRW	MES100,10;PLATFORMS
	.DRW	MES105,11;TRASH CANS
	.DRW	MES106,12;TNT WORLD
	.DRW	MES107,13;SNAKE WORLD
	.DRW	MES108,14;HORNS WORLD
	.DRW	MES109,15;POPCORN WORLD
	.DRW	MES109A,16;PARADE 
	.DRW	MES109C,18;BOSS ROOM 
	.DRW	MES109B,19;SQUISHI 
	.DRW	0
	
MES10: 	.DB	WRITEVID	       
	.DRW	WORLD1
	.DB	14,12,0,9
	.DB	TEXTWRITE
	.DRW	IBEAM
	.DB	SKIP
	.DRW	MS110

MES20: 	.DB	WRITEVID	       
	.DRW	WORLD2
	.DB	14,12,0,9
	.DB	TEXTWRITE
	.DRW	PARACH
	.DB	SKIP
	.DRW	MS110

MES30: 	.DB	WRITEVID	       
	.DRW	WORLD3
	.DB	14,10,0,11
	.DB	TEXTWRITE
	.DRW	PIPES
	.DB	SKIP
	.DRW	MS110

MES40: 	.DB	WRITEVID	       
	.DRW	WORLD4
	.DB	14,11,0,10
	.DB	TEXTWRITE
	.DRW	SNIPE
	.DB	SKIP
	.DRW	MS110

MES50: 	.DB	WRITEVID	       
	.DRW	WORLD5
	.DB	14,11,0,10
	.DB	TEXTWRITE
	.DRW	JUNGLE
	.DB	SKIP
	.DRW	MS110

MES60: 	.DB	WRITEVID	       
	.DRW	WORLD6
	.DB	14,12,0,9
	.DB	TEXTWRITE
	.DRW	LIPS
	.DB	SKIP
	.DRW	MS110

MES70: 	.DB	WRITEVID	       
	.DRW	WORLD7
	.DB	14,10,0,11
	.DB	TEXTWRITE
	.DRW	CANNONS
	.DB	SKIP
	.DRW	MS110

MES80: 	.DB	WRITEVID	       
	.DRW	WORLD8
	.DB	14,10,0,11
	.DB	TEXTWRITE
	.DRW	FIRE
	.DB	SKIP
	.DRW	MS110

MES90: 	.DB	WRITEVID	       
	.DRW	WORLD9
	.DB	14,11,0,10
	.DB	TEXTWRITE
	.DRW	BUNGEE
	.DB	SKIP
	.DRW	MS110

MES100:	.DB	WRITEVID	       
	.DRW	WORLD10
	.DB	14,12,0,9
	.DB	TEXTWRITE
	.DRW	PLATFO
	.DB	SKIP
	.DRW	MS110

MES105:	.DB	WRITEVID	       
	.DRW	WORLD11
	.DB	14,10,0,12
	.DB	TEXTWRITE
	.DRW	GARBAGE
	.DB	SKIP
	.DRW	MS110

MES106:	.DB	WRITEVID	       
	.DRW	WORLD12
	.DB	14,10,0,12
	.DB	TEXTWRITE
	.DRW	TNTTEXT
	.DB	SKIP
	.DRW	MS110

MES107:	.DB	WRITEVID	       
	.DRW	WORLD13
	.DB	14,9,0,14
	.DB	TEXTWRITE
	.DRW	SNKTEXT
	.DB	SKIP
	.DRW	MS110

MES108:	.DB	WRITEVID	       
	.DRW	WORLD14
	.DB	14,9,0,14
	.DB	TEXTWRITE
	.DRW	HORNTEXT
	.DB	SKIP
	.DRW	MS110

MES109:
	.DB	WRITEVID	       
	.DRW	WORLD15
	.DB	14,9,0,13
	.DB	TEXTWRITE
	.DRW	POPTEXT
	.DB	SKIP
	.DRW	MS110

MES109A:
	.DB	TEXTWRITE
	.DRW	PARATEXT
	.DB	SETREG,17,0	;GO TO PARADE
	.DB	STORE,57
	.DB	SKIP
	.DRW	MS110

MES109B:
	.DB	WRITEVID	       
	.DRW	WORLD16
	.DB	14,9,0,14
	.DB	TEXTWRITE
	.DRW	SQUTEXT
	.DB	SETREG,19,0	;GO TO PARADE
	.DB	STORE,57
	.DB	SKIP
	.DRW	MS110

MES109C:
	.DB	TEXTWRITE
	.DRW	BOSSTEXT
	.DB	SETREG,18,0	;GO TO BOSS
	.DB	STORE,57


MS110:	.DB	JOYSTICK,0
MS115:	.DB	BUTTON
	.DRW	MS120
	.DB	A_BUTTON|B_BUTTON|START|SELECT
	.DB	SKIP
	.DRW	MS115	

MS120:	.DB	SOUND
	.DRW	0,0,0,0
	.DB	LOAD,57
	.DB	WORLD,REGISTER


WORLD1:.DB	"ARENA ONE"
WORLD2:.DB    	"ARENA TWO"
WORLD3:.DB    	"ARENA THREE"
WORLD4:.DB    	"ARENA FOUR"
WORLD5:.DB	"ARENA FIVE"
WORLD6:.DB	"ARENA SIX"
WORLD7:.DB	"ARENA SEVEN"
WORLD8:.DB	"ARENA EIGHT"
WORLD9:.DB	"ARENA NINE"
WORLD10:.DB	"ARENA TEN"
WORLD11:.DB	"ARENA ELEVEN"
WORLD12:.DB	"ARENA TWELVE"
WORLD13:.DB	"ARENA THIRTEEN"
WORLD14:.DB	"ARENA FOURTEEN"
WORLD15:.DB	"ARENA FIFTEEN"
WORLD16:.DB	"FINAL CONFLICT"

PARATEXT:
	.DB	-1
	.DRW	H'2268
	.DB	"GIVE HIM A HAND!"
	.DB	0	

IBEAM:
	.DB	-1
	.DRW	H'2269
	.DB	"THE SLICK BEAM"
	.DB	0	
PARACH:
	.DB	-1
	.DRW	H'2269
	.DB	"HAPPY LANDING!"
	.DB	0	
PIPES:
	.DB	-1
	.DRW	H'2269
	.DB	"DON'T BLOW IT!"
	.DB	0	
SNIPE:
	.DB	-1
	.DRW	H'2269
	.DB	"AIM CAREFULLY!"
	.DB	0	
JUNGLE:
	.DB	-1
	.DRW   	H'2269
	.DB	"JUNGLE HIKERS "
	.DB	0	
LIPS:
	.DB	-1
	.DRW	H'2269
	.DB	"WATCH YO MOUTH"
	.DB	0	
CANNONS:
	.DB	-1
	.DRW	H'2269
	.DB	"FIRE AT WILL! "
	.DB	0	
FIRE:
	.DB	-1
	.DRW	H'2269
	.DB	"ITS A SCORCHER"
	.DB	0	
BUNGEE:
	.DB	-1
	.DRW	H'2269
	.DB	"LET'S BUNGEE! "
	.DB	0	
PLATFO:
	.DB	-1
	.DRW	H'2269
	.DB	"PLATFORM HELL "
	.DB	0	
GARBAGE:
	.DB	-1
	.DRW	H'2269
	.DB	" DUMP IT OUT! "
	.DB	0	
SNKTEXT:
	.DB	-1
	.DRW	H'2269
	.DB	" SPAZ SERPENT "
	.DB	0	
TNTTEXT:
	.DB	-1
	.DRW	H'2269
	.DB	"EXPLOSIVE FUN!"
	.DB	0	

HORNTEXT:
	.DB	-1
	.DRW	H'2269
	.DB	"ALL THAT JAZZ "
	.DB	0	

POPTEXT:
	.DB	-1
	.DRW	H'2269
	.DB	"POP! POP! POP!"
	.DB	0	

SQUTEXT:
	.DB	-1
	.DRW	H'2269
	.DB	"SQUISHI TIME! "
	.DB	0	

BOSSTEXT:
	.DB	-1
	.DRW	H'2269
	.DB	"ARM THAT HAND!"
	.DB	0	

;---------------------------------------------------------------------

	.DRW	GARB1
	.DB	0
TRASH:	.DRW	DUMMY,TRSHCODE
	.DB	0,-1,0,0,0

TRSHCODE:
	.DB	INSTRUCTIONS,8
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	SOLIDSTATE,OFF

TRSH5:	.DB	FETCHREG,RANDOM		 	;GET Y LOCATION
	.DB	COMPARE
	.DRW	TRSH6
	.DRW	80
	.DB	SKIP
	.DRW	TRSH5
TRSH6:	.DB	COMPARE
	.DRW	TRSH5
	.DRW	136	

	.DB	RANDOM
	.DRW	TRSH20
	.DB	127
	.DB	GOTO,69,REGISTER
	.DB	ANIMATION,3,RESERVE
	.DB	DISPLAY,BEHIND
	.DB	SETMOM,16,0
	.DB	DELAY,9
TRSH10:	.DB	SETMOM,16,0
	.DB	XVISUAL
	.DRW	TRSH15
	.DB	196  
	.DB	DIE,0	
TRSH15:	.DB	RANDOM
	.DRW	TRSH10
	.DB	225
	.DB	LAUNCH,19,8,12,0
	.DB	SKIP
	.DRW	TRSH10

TRSH20:	.DB	GOTO,179,REGISTER
	.DB	ANIMATION,3,RESERVE
	.DB	DISPLAY,BEHIND
	.DB	SETMOM,-16,0
	.DB	DELAY,9
TRSH25:	.DB	SETMOM,-16,0
	.DB	XVISUAL
	.DRW	SAFEDIE
	.DB	56     
	.DB	RANDOM
	.DRW	TRSH25
	.DB	225
	.DB	LAUNCH,19,24,12,0
	.DB	SKIP
	.DRW	TRSH25


;--------------------------------------------
	.DRW	SNKBIT		;MOUTH BITING
	.DB	0
	.DRW	SNAK2 		;TAIL
	.DB	0
BUMPER:	.DRW	SNAK1,BUMPCODE
	.DB	0,-2,0,0,0

BUMPCODE:
	.DB	INSTRUCTIONS,7
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	TARGET	
	.DRW	KILLER|SUPPLY
	.DB	FETCHREG,PARAM2
	.DB	CASE
	.DRW	BMP5,1	;TAIL
	.DRW	BMP6,2	;HEAD
	.DRW	0
	.DB	SKIP
	.DRW	BMP10

BMP5:	.DB	ANIMATION,3,RESERVE
	.DB	SKIP
	.DRW	BMP10

BMP6:	.DB	ANIMATION,6,RESERVE

BMP10: 	.DB	SETMOM,24,0 
	.DB	TESTSOLID
	.DRW	BMP15
	.DB	1,0
	.DB	SKIP
	.DRW	BMP10

BMP15:
	.DB	SETMOM,-24,0 
	.DB	TESTSOLID
	.DRW	BMP10
	.DB	-1,0
	.DB	SKIP
	.DRW	BMP15


;---------------------------------------------------------------------
BDUMB:
	.DRW	DUMMY,BDUMCODE
	.DB	0,-1,0,0,0

BDUMCODE:
	.DB	GRAVITY,0
	.DB	DELAY,20
	.DB	RANDOM
	.DRW	BDUMCODE
	.DB	200
 	.DB	LAUNCH,22,0,0,0			;DROP FLAMES
	.DB	SKIP
	.DRW	BDUMCODE

;----------------------------------------------------------------
	.DRW	DYNS
	.DB	0	
	.DRW	TNTS
	.DB	0	
DYNAMITE:
	.DRW	DUMMY,DYNCODE
	.DB	0,-1,0,0,0

DYNCODE:.DB	GRAVITY,0
DYN10:	.DB	FETCHREG,RANDOM	 	;LOCATION CODE	
	.DB	COMPARE
	.DRW	DYN15
	.DRW	69
	.DB	SKIP
	.DRW	DYN10
DYN15:	.DB	COMPARE
	.DRW	DYN10
	.DRW	180

	.DB	GOTO,REGISTER,-1
	.DB	ANIMATION,3,RESERVE
	.DB	SETMOM,0,32 		;FALL 
	.DB	DELAY,13
	.DB	SETMOM,0,0   		;STOP AND EXPLODE
	.DB	ANIMATION,6,RESERVE
	.DB	NOISE
	.DRW	THUNSND
	

	.DB	LAUNCH,31,0,0,1		;LAUNCH DUDES
	.DB	PALCLR,0,H'30
	.DB	DELAY,4
	.DB	LAUNCH,31,0,0,2		;LAUNCH DUDES
	.DB	PALCLR,0,H'21
	.DB	DELAY,4
	.DB	LAUNCH,31,0,0,3		;LAUNCH DUDES
	.DB	PALCLR,0,H'07
	.DB	DELAY,4
	.DB	LAUNCH,31,0,0,4		;LAUNCH DUDES
	.DB	PALCLR,0,H'3A

DYN20:	.DB	BPALETTE
	.DRW	-1
	.DB	DIE,0

;-------------------------------------------
	.DRW	MANS1
	.DB	0
	.DRW	MANS3
	.DB	0
	.DRW	MANS4
	.DB	0
	.DRW	MANWALK 	    
	.DB	0
BOOTDUDE:      
	.DRW	DUMMY,BDCODE
	.DB	0,-1,0,0,0

BDCODE:
	.DB	SOLIDSTATE,ON
		
BDC10:	.DB	FETCHREG,RANDOM	 	;LOCATION CODE	
	.DB	COMPARE
	.DRW	BDC15
	.DRW	53
	.DB	SKIP
	.DRW	BDC10
BDC15:	.DB	COMPARE
	.DRW	BDC10
	.DRW	179

	.DB	GOTO,REGISTER,-1
	.DB	NOTSTANDING
	.DRW	BDC25
BDC19:	.DB	GRAVITY,-1 
	.DB	ANIMATION,3,RESERVE

BDC20:	.DB	RANDOM		;DETERMINE DIRECTION
	.DRW	BDC24
	.DB	127	
BDC23:	.DB	NOTSTANDING
	.DRW	BDC25 
	.DB	SETMOM,8,0
	.DB	SKIP
	.DRW	BDC23
BDC24:	.DB	NOTSTANDING
	.DRW	BDC25 
	.DB	SETMOM,-8,0
	.DB	SKIP
	.DRW	BDC24

BDC25: 
	.DB	GRAVITY,0
	.DB	FACE,TRAVELING
	.DB	RANDOM
	.DRW	BDC26
	.DB	127
	.DB	ANIMATION,6,RESERVE
	.DB	SKIP
	.DRW	BDC30
BDC26:	.DB	RANDOM
	.DRW	BDC27
	.DB	127
	.DB	ANIMATION,9,RESERVE
	.DB	SKIP
	.DRW	BDC30
BDC27:	.DB	ANIMATION,12,RESERVE
	
BDC30: 	.DB	STANDING      		;FALLING CODE
	.DRW	BDC19
	.DB	SETMOM,0,24
	.DB	YVISUAL			       
	.DRW	BDC30
	.DB	232
	.DB	SKIP
	.DRW	SAFEDIE


;------------------------------------------------------------------------
VOMCODE:
	.DRW	VOMIT,VOMMY
	.DB	0,-2,0,0,0


VOMMY:
	.DB	SOLIDSTATE,OFF
	.DB	TARGET
	.DRW	HERO0
VOM10:	.DB	YVISUAL
	.DRW	VOM10
	.DB	208
	.DB	DIE,0

;---------------------------------------------------------------------
ENDDUDE:
	.DRW	MANCARI,ENDD10 		;MAKE MANY MEN
	.DB	0,-1,0,0,0

ENDD10:	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	FACE,TRAVELING

ENDD15:	.DB	SETMOM,8,0
	.DB	DELAY,190

ENDD20:	.DB	SETMOM,-8,0
	.DB	DELAY,190
	.DB	SKIP
	.DRW	ENDD15
;---------------------------------------------------------------------

ENDHAND:.DRW	HANDWAV,ENDH10		    
	.DB	0,-1,0,0,0

ENDH10:	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	JOYSTICK,0
	.DB	SETPAUSE,OFF
	.DB	LINKFACE,ON
	.DB	FACE,RIGHT
	.DB	LINK,CENTERED,-32,ID
	.DRW	35

	.DB	FETCHREG,WORLD
	.DB	EQUAL
	.DRW	ENDH35
	.DRW	20		;CREDITS
	
	.DB	INSTRUCTIONS,9
;	.DB	LOAD,26	  	;SAVED
;	.DB	SHOWREG,8,5,0
;	.DB	WRITEVID
;	.DRW	SAVED
;	.DB	8,1,0,5
;	.DB	LOAD,24	  	;LOST
;	.DB	SHOWREG,8,14,0
;	.DB	WRITEVID
;	.DRW	LOST
;	.DB	8,11,0,4
	.DB	WRITEVID
	.DRW	ENDSCORE
	.DB	8,7,0,11	    	     ;8,20,0,5
	.DB	SHOWSCORE,JOY1,8,19,0  	     ;8,25,0	

ENDH20:	.DB	BUTTON
	.DRW	ENDH30
	.DB     START
	.DB	SKIP
	.DRW	ENDH20

ENDH30:	.DB	WORLD,20	;CREDITS


ENDH35:	.DB	BUTTON
	.DRW	ENDH40
	.DB     START
	.DB	SKIP
	.DRW	ENDH35

ENDH40:	.DB	WORLD,17 ;GO BACK TO PARADE

ENDSCORE:
	.DB	"FINAL SCORE"
LOST:  	.DB	"LOST"

;----------------------------------------------------------------------


	.DRW	MANN	   	;30
	.DB	0
	.DRW	MANSB	   	;27
	.DB	0
	.DRW	MANSA	   	;24
	.DB	0
	.DRW	MANS9	   	;21
	.DB	0
	.DRW	MANJ	   	;18
	.DB	0
	.DRW	MANS8	   	;15
	.DB	0
	.DRW	MANG
	.DB	0
	.DRW	MANS7
	.DB	0
	.DRW	MANS6
	.DB	0
	.DRW	MANS5
	.DB	0
FAN1:	.DRW	DUMMY,FANCODE
	.DB	0,-1,0,0,0


FANCODE:.DB	GRAVITY,0
	.DB	HALFFREQ,ON
	.DB	FETCHREG,PARAM2
	.DB	CASE
	.DRW	FAN5,5
	.DRW	FAN6,6
	.DRW	FAN7,7
	.DRW	FAN8,8
	.DRW	FAN9,9
	.DRW	FAN10,10
	.DRW	FAN11,11
	.DRW	0

FAN5:	.DB	ANIMATION,3,RESERVE	;GUY WAVING 
FAN5A:	.DB	DELAY,13 
	.DB	RANDOM
	.DRW	FAN5A
	.DB	230
	.DB	ANIMATION,12,RESERVE
	.DB	DELAY,80
	.DB	SKIP
	.DRW	FAN5	

FAN6:	.DB	ANIMATION,6,RESERVE	;HEIL! 
FAN6A:	.DB	DELAY,13 
	.DB	RANDOM
	.DRW	FAN6A
	.DB	230
	.DB	ANIMATION,12,RESERVE
	.DB	DELAY,80
	.DB	SKIP
	.DRW	FAN6 
	
FAN7:	.DB	ANIMATION,9,RESERVE	;WAVE 2 
FAN7A: 	.DB	DELAY,13
	.DB	RANDOM
	.DRW	FAN7A
	.DB	230
	.DB	ANIMATION,12,RESERVE
	.DB	DELAY,80
	.DB	SKIP
	.DRW	FAN7	

FAN8:	.DB	ANIMATION,15,RESERVE	;SIT JUMP 
	.DB	DELAY,80
FAN8A:	.DB	RANDOM
	.DRW	FAN8
	.DB	200
	.DB	ANIMATION,27,RESERVE
	.DB	DELAY,80
	.DB	SKIP
	.DRW	FAN8 
	
;STANDING FANS

FAN9:	.DB	ANIMATION,21,RESERVE	;STANDING WAVE 
FAN9A:	.DB	DELAY,13 
	.DB	RANDOM
	.DRW	FAN9A
	.DB	230
	.DB	ANIMATION,18,RESERVE
	.DB	DELAY,80
	.DB	SKIP
	.DRW	FAN9 

FAN10: 	.DB	SOUNDBUSY
	.DRW	FAN10AA
	.DB	ON,ON,ON,ON
 	.DB	SOUND
	.DRW	POLLSONG,POLLBASS,POLLDRUM,0
FAN10AA:.DB	ANIMATION,24,RESERVE	;DANCING 
FAN10A:	.DB	DELAY,67 
	.DB	RANDOM
	.DRW	FAN10A
	.DB	220
	.DB	ANIMATION,30,RESERVE
	.DB	DELAY,53
	.DB	SKIP
	.DRW	FAN10
 
FAN11:	.DB	ANIMATION,27,RESERVE	;JUMP 
FAN11A:	.DB	DELAY,13 
	.DB	RANDOM
	.DRW	FAN11A
	.DB	230
	.DB	ANIMATION,30,RESERVE
	.DB	DELAY,80
	.DB	SKIP
	.DRW	FAN11 

;---------------------------------------------------------------------
CREDITS:.DRW	DUMMY,CREDCODE
	.DB	0,-1,0,0,0

CREDCODE:
	.DB	GRAVITY,0
CRED11:	.DB	TEXTWRITE
	.DRW	CREDS
	.DB	DIE,0

CREDS:
	.DB	-1
	.DRW	H'2122
	.DB	"DESIGNED, PROGRAMMED,"
	.DB	-2
	.DRW	H'0020
	.DB	"PIXELIZED, AND SCORED BY:"
	.DB	-2
	.DRW	H'0040
	.DB	"     ROGER DEFOREST"
	.DB	-2
	.DRW	H'0060
	.DB	"WITH INVALUABLE HELP FROM:" 
	.DB	-2
	.DRW	H'0040
	.DB	"VANCE KOZIK, JIM TREADWAY,"
	.DB	-2
	.DRW	H'0020
	.DB	"TONY BERRIOS, DAVID BRAUN,"
	.DB	-2
	.DRW	H'0020
	.DB	"GORDON JUNG, DAN BURKE,"
	.DB	-2
	.DRW	H'0020
	.DB	"AND SCOTT DUCKETT"
	.DB	-2
	.DRW	H'0060
	.DB	"COSMIC SANITY SUPPLIED BY:"
	.DB	-2
	.DRW	H'0040
	.DB	"THE MYSTERIOUS AMY EHMANN"
	.DB	0

;---------------------------------------------------------------------

	.DRW	MANS9
	.DB	0
WALKER:	.DRW	MANWALK,WALKCODE
	.DB	0,-1,0,0,0

WALKCODE:
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
WLK10:	.DB	SETMOM,8,0
	.DB	RANDOM
	.DRW	WLK15
	.DB	245
	.DB	SETMOM,0,0
	.DB	ANIMATION,3,RESERVE
	.DB	DELAY,40    
	.DB	ANIMATION,EWAKE,2
WLK15:	.DB	XVISUAL
	.DRW	WLK10
     	.DB	192

WLK20:	.DB	SETMOM,-8,0
	.DB	RANDOM
	.DRW	WLK25
	.DB	245
	.DB	SETMOM,0,0

	.DB	ANIMATION,3,RESERVE
	.DB	DELAY,33	
	.DB	ANIMATION,EWAKE,2
WLK25:	.DB	XVISUAL
	.DRW	WLK10
     	.DB	64
	.DB	SKIP
	.DRW	WLK20

;---------------------------------------------------------------------

FREE:	.DRW	PRZHAND,FREECODE
	.DB	0,-1,0,0,0

FREECODE:
	.DB	INSTRUCTIONS,9
	.DB	GRAVITY,0
	.DB	SOLIDSTATE,OFF
	.DB	NOISE
	.DRW	FREESND
	.DB	SETMOM,0,0
	.DB	ADDHEROS,JOY1,1
	.DB	GETHEROS,JOY1
	.DB	SHOWREG,24,1,0
	.DB	DELAY,60
	.DB	DIE,0
	
;---------------------------------------------------------------------
	.DRW	DUMMY
	.DB	0
	.DRW	JETS
	.DB	0
JET:	.DRW	DUMMY,JETCODE
	.DB	0,-1,0,0,0
	.DRW	-1,JETHURT
	.DB	0,-1,0,0,0
	
JETCODE:
	.DB	GRAVITY,0
	.DB	SOLIDSTATE,OFF
	.DB	IDENTIFY
	.DRW	DEADLY
	.DB	ENABLE,HURTING

	.DB	RANDOM
	.DRW	JET20
	.DB	127
	.DB	GOTO,69,100
	.DB	SETMOM,2,0
	.DB	ANIMATION,3,RESERVE
JET10:	.DB	SETMOM,16,0
	.DB	NOISE
	.DRW	JETSND
	.DB	XVISUAL
	.DRW	JET10
	.DB	179  
	.DB	SKIP
	.DRW	JET25

JET20: 	.DB	GOTO,179,100
	.DB	SETMOM,-2,0
	.DB	ANIMATION,3,RESERVE
JET25:	.DB	SETMOM,-16,0
	.DB	NOISE
	.DRW	JETSND
	.DB	XVISUAL
	.DRW	JET10
	.DB	69     
	.DB	SKIP
	.DRW	JET25

JETHURT:
	.DB	IDENTIFY
	.DRW	SUPPLY
	.DB	ENABLE,HURTING
	.DB	ATTACKER
	.DRW	JET30
	.DB	6	 		;CATCHER ONE

JET26:	.DB	SETMOM,-1,-16		;FLY UP WHEN HIT
	.DB	NOISE
	.DRW	JETSND
	.DB	YVISUAL
	.DRW	SAFEDIE
	.DB	20
	.DB	SKIP
	.DRW	JET26	     


JET30:	.DB	INSTRUCTIONS,6
 	.DB	ANIMATION,6,RESERVE
	.DB	NOISE	 	  	;HE'S IN CATCHER
	.DRW	INCAT
JET35: 	.DB	INSTRUCTIONS,12
	.DB	LOAD,53
	.DB	ADD			;ADD 5 TO SAVED COUNT
	.DRW	1
	.DB	STORE,53
	.DB	SHOWREG,20,26,0	     
	.DB	NOISE
	.DRW	ADDIT
;	.DB	LOAD,26			;SAVER COUNT
;	.DB	ADD
;	.DRW	1
;	.DB	STORE,26
	.DB	LOAD,53
	.DB	COMPAREDATA,25
	.DRW	TIM10

	.DB	LOAD,61			;COUNTER
	.DB	ADD
	.DRW	1
	.DB	STORE,61
	.DB	EQUAL
	.DRW	JET40
	.DRW	10	
	.DB	SKIP
	.DRW	JET35

JET40:	.DB	SETREG,0,0	;ZERO COUNTER
	.DB	STORE,61
	.DB	DIE,0


;---------------------------------------------------------------------
	.DRW	RAB2
	.DB	0
	.DRW	RAB1
	.DB	0
HOPPER:	.DRW	DUMMY,HOPCODE
	.DB	0,-2,0,0,0

HOPCODE:
	.DB	ACTIVE
	.DRW	SAFEDIE
	.DB	ID
	.DRW	42
	.DB	DISPLAY,BEHIND
	.DB	MOMLIMIT,-1,32
	.DB	GRAVITY,-1
	.DB	FRICTION,0,0
	.DB	SOLIDSTATE,OFF
	.DB	TARGET
	.DRW	HERO0
	.DB	RANDOM
	.DRW	HOP20
	.DB	127
	.DB	GOTO,69,120
	.DB	SETMOM,8,0
	.DB	ANIMATION,3,RESERVE
		
HOP10: 	.DB	YVISUAL
	.DRW	HOP10
	.DB	192
	.DB	MOMLIMIT,32,40
	.DB	ANIMATION,6,RESERVE
	.DB	GRAVITY,0
	.DB	SETMOM,0,0
	.DB	DELAY,4
	.DB	ANIMATION,3,RESERVE
	.DB	NOISE
	.DRW	JUMPSND
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40
	.DB	SETMOM,24,-40
	.DB	GRAVITY,-1
	.DB	XVISUAL
	.DRW	HOP10
	.DB	179
	.DB	DIE,0


HOP20:	.DB	GOTO,179,120
	.DB	SETMOM,-8,0
	.DB	FACE,LEFT
	.DB	ANIMATION,3,RESERVE

HOP25:	.DB	YVISUAL
	.DRW	HOP25
	.DB	192
	.DB	MOMLIMIT,32,40
	.DB	ANIMATION,6,RESERVE
	.DB	GRAVITY,0
	.DB	SETMOM,0,0
	.DB	DELAY,4
	.DB	ANIMATION,3,RESERVE
	.DB	NOISE
	.DRW	JUMPSND
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	SETMOM,-24,-40
	.DB	GRAVITY,-1
	.DB	XVISUAL
	.DRW	SAFEDIE
	.DB	77
	.DB	SKIP
	.DRW	HOP25
	
;---------------------------------------------------------------------
	.DRW	BOSSPOP		 	;POP
	.DB	H'40
      	.DRW	BOSS6		 	;INVISIBLE
	.DB	0
	.DRW	BOSSDIE
	.DB	H'40
BOSSGUY:
	.DRW	BOSSES,BOSSCODE
	.DB	0,-1,0,0,0
	.DRW	BOSHURT,BOSSHURT
	.DB	0,-1,0,0,0
	.DRW	BOSSES,BOSS8A	;EFALL
	.DB	0,-1,0,0,0

BOSSCODE:	
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	SETREG,0,0
	.DB	STORE,58
	.DB	IDENTIFY
	.DRW	ENEMY
	.DB	TARGET
	.DRW	HERO0
	.DB	MOMLIMIT,72,72

;FIRST PRINT WARNING MESSAGE!
	.DB	WRITEVID
	.DRW	WARN1	   	;LOOK OUT!
	.DB	17,8,0,16	
	.DB	WRITEVID
	.DRW	WARN2	   	;THIS GUY IS MAD!
	.DB	20,8,0,16  
	
	.DB	DELAY,70
			      	;ERASE
	.DB	WRITEVID
	.DRW	ERASE	   	
	.DB	17,8,0,16	
	.DB	WRITEVID
	.DRW	ERASE	   	
	.DB	20,8,0,16  
	
BOSS8A:	.DB	ENABLE,HURTING 		;DETERMINES WHICH BOSS TO USE
	.DB	LOAD,57
	.DB	CASE
	.DRW	BOSS9,5
	.DRW	BOSS60,10
	.DRW	BOSS30,18
	.DRW	0

BOSS9:	.DB	FETCHREG,RANDOM
	.DB	ANDREG
	.DRW	H'50
	.DB	SETCOUNTER,REGISTER
BOSS10:	.DB	SETMOM,72,0		       ;GO ACROSS SCREEN
	.DB	TESTSOLID
	.DRW	BOSS16
	.DB	1,0
	.DB	ABOVECOUNT
	.DRW	BOSS10
	.DB	0
BOSS11:	.DB	LAUNCH,44,0,32,0		;DROP BOMBS
	.DB	SKIP
	.DRW	BOSS9	

BOSS14:	.DB	FETCHREG,RANDOM
	.DB	ANDREG
	.DRW	H'50
	.DB	SETCOUNTER,REGISTER
BOSS15:	.DB	SETMOM,-72,0		;GO ACROSS SCREEN
	.DB	TESTSOLID
	.DRW	BOSS11
	.DB	-1,0
	.DB	ABOVECOUNT
	.DRW	BOSS15
	.DB	0
BOSS16:	.DB	LAUNCH,44,0,32,0		;DROP BOMBS
	.DB	SKIP
	.DRW	BOSS14	
	
BOSSHURT:
	.DB	INSTRUCTIONS,9
	.DB	DISABLE,HURTING
	.DB	SETMOM,0,0
	.DB	NOISE
	.DRW	BSHURT
	.DB	DAMAGE
	.DB	ASSESS
	.DRW	BOSS20
	.DB	0
	.DB	DELAY,20
	.DB	ACTIVATE,EFALL

BOSS20:	.DB	INSTRUCTIONS,11
	.DB	JOYSTICK,0
	.DB	SETREG,1,0 	    	;BOSS IS DEAD
	.DB	STORE,58
	.DB	HURT,0,ID 	;GET RID OF BOMBS
	.DRW	44
	.DB	HURT,0,ID 	;GET RID OF BOMBS
	.DRW	46
	.DB	HURT,0,ID 	;GET RID OF OBSATCLES
	.DRW	47
	.DB	HURT,0,ID 	;GET RID OF BOMBS
	.DRW	48
	.DB	SOUND
	.DRW	0,0,WINRIF1,WINRIF2
	.DB	ANIMATION,3,RESERVE
	.DB	FINISH
	.DB	DELAY,90
	.DB	NOISE
	.DRW	POPSND
	.DB	ANIMATION,9,RESERVE
	.DB	SKIP
	.DRW	HH57		


BOSS30:	.DB	SETCOUNTER,40
	.DB	DISABLE,HURTING
BOSS35:	.DB	INSTRUCTIONS,3
	.DB	FETCHREG,RANDOM	 	;GET X COORDINATE
	.DB	COMPARE
	.DRW	BOSS40
	.DRW	69
	.DB	SKIP
	.DRW	BOSS35
BOSS40:	.DB	INSTRUCTIONS,2
	.DB	COMPARE
	.DRW	BOSS35
	.DRW	179
	.DB	GOTO,REGISTER,-1
		
BOSS45:	.DB	INSTRUCTIONS,3
	.DB	FETCHREG,RANDOM	 	;GET Y COORDINATE
	.DB	COMPARE
	.DRW	BOSS50
	.DRW	64
	.DB	SKIP
	.DRW	BOSS45
BOSS50:	.DB	INSTRUCTIONS,2
	.DB	COMPARE
	.DRW	BOSS45
	.DRW	144
	.DB	GOTO,-1,REGISTER
		
	.DB	INSTRUCTIONS,7
	.DB	ANIMATION,EWAKE,2
	.DB	NOISE
	.DRW	ADDIT       
	.DB	COUNT
	.DRW	BOSS55
	.DB	1
	.DB	DELAY,1
	.DB	ANIMATION,6,RESERVE
	.DB	SKIP
	.DRW	BOSS35		

BOSS55:	.DB	INSTRUCTIONS,8
	.DB	ENABLE,HURTING
	.DB	DELAY,30
	.DB	LAUNCH,46,0,32,2
	.DB	LAUNCH,46,0,32,1
	.DB	LAUNCH,46,0,32,3
	.DB	DELAY,20
	.DB	ANIMATION,6,RESERVE
	.DB	SKIP
	.DRW	BOSS30


BOSS60:	.DB	INSTRUCTIONS,5	
	.DB	ACTIVE
	.DRW	BOSS61
	.DB	ID
	.DRW	47
	.DB	CREATE,47,56,72,0	;MAKE OBSTACLES
	.DB	CREATE,47,168,128,0

BOSS61:	.DB	SETMOM,24,0	       ;GO ACROSS SCREEN
	.DB	DISTANCE
	.DRW	BOSS63
	.DB	8,-1
BOSS62:	.DB	TESTSOLID
	.DRW	BOSS65
	.DB	1,0
	.DB	SKIP
	.DRW	BOSS61	
BOSS63:	.DB	LAUNCH,48,0,32,0
	.DB	SKIP
	.DRW	BOSS62	


BOSS65:	.DB	SETMOM,-24,0		;GO ACROSS SCREEN
	.DB	DISTANCE
	.DRW	BOSS67
	.DB	8,-1
BOSS66:	.DB	TESTSOLID
	.DRW	BOSS61
	.DB	-1,0
	.DB	SKIP
	.DRW	BOSS65	
BOSS67:	.DB	LAUNCH,48,0,32,0
	.DB	SKIP
	.DRW	BOSS66	
	

WARN1:	.DB	"   LOOK OUT!    "	

WARN2:	.DB	"THIS GUY IS MAD!"	


;---------------------------------------------------------------------
BOSSHIT1:
	.DRW	BOBOMS,SHITC1
	.DB	0,-2,0,0,0
	.DRW	-1,SAFEDIE
	.DB	0,-1,0,0,0

SHITC1:
	.DB	GRAVITY,0
	.DB	TARGET
	.DRW	HERO0
	.DB	ENABLE,HURTING
	.DB	MOMLIMIT,1,56

	.DB	NOISE
	.DRW	SQUSHOT
SHIT10:	.DB	SETMOM,0,48
	.DB	ATTACKED
	.DRW	SAFEDIE
	.DB	YVISUAL
	.DRW	SHIT10
	.DB	208

	.DB	DIE,0	


;---------------------------------------------------------------------	

BOSSHIT2:
	.DRW	BOBOMS,SHITC2
	.DB	0,-2,0,0,0
	.DRW	-1,SAFEDIE
	.DB	0,-1,0,0,0


SHITC2:	.DB	INSTRUCTIONS,8
	.DB	GRAVITY,0
	.DB	TARGET
	.DRW	HERO0
	.DB	SOLIDSTATE,OFF
	.DB	MOMLIMIT,64,64
	.DB	ENABLE,HURTING
	.DB	NOISE
	.DRW	SQUSHOT
	.DB	FETCHREG,PARAM2
	.DB	CASE
	.DRW	SHIT20,1
	.DRW	SHIT25,2
	.DRW	SHIT30,3
	.DRW	0
		
SHIT20:	.DB	SETMOM,-64,64 	;DOWN LEFT
	.DB	ATTACKED
	.DRW	SAFEDIE
	.DB	YVISUAL
	.DRW	SHIT20
	.DB	208
	.DB	DIE,0
	
SHIT25:	.DB	SETMOM,0,64 	;STRAIGHT DOWN
	.DB	ATTACKED
	.DRW	SAFEDIE
	.DB	YVISUAL
	.DRW	SHIT25
	.DB	208
	.DB	DIE,0
	
SHIT30:	.DB	SETMOM,64,64 	;DOWN RIGHT
	.DB	ATTACKED
	.DRW	SAFEDIE
	.DB	YVISUAL
	.DRW	SHIT30
	.DB	208
	.DB	DIE,0
	
;---------------------------------------------------------------------
	.DRW	BOBOMS
	.DB	0
BOSSHIT3:
	.DRW	DUMMY,SHITC3
	.DB	0,-2,0,0,0
	.DRW	-1,SAFEDIE
	.DB	0,-1,0,0,0

SHITC3:	.DB	INSTRUCTIONS,8
	.DB	ACTIVE
	.DRW	SAFEDIE
	.DB	ID
	.DRW	48
	.DB	GRAVITY,0	
	.DB	TARGET
	.DRW	HERO0
	.DB	ANIMATION,3,RESERVE
	.DB	SOLIDSTATE,OFF
	.DB	ENABLE,HURTING
	.DB	NOISE
	.DRW	SQUSHOT

SHIT35:	.DB	SETMOM,0,24
	.DB	ATTACKED
	.DRW	SAFEDIE
	.DB	YVISUAL
	.DRW	SHIT35
	.DB	208
	.DB	DIE,0



;---------------------------------------------------------------------

	.DRW	DUMMY
	.DB	0
BOSSOBST:	
	.DRW	PLATTB,BOBSTCODE
	.DB	0,-1,0,0,0
	.DRW	PLATTB,BOBSTHURT
	.DB	0,-1,0,0,0


BOBSTCODE:
	.DB	GRAVITY,0
	.DB	IDENTIFY
	.DRW	DEADLY
	.DB	TARGET
	.DRW	HERO0
	.DB	ENABLE,HURTING
	.DB	FETCHREG,PARAM2
	.DB	EQUAL
	.DRW	BOBS34
	.DRW	1

BOBS10:	.DB	SETMOM,40,0	       ;GO ACROSS SCREEN
	.DB	TESTSOLID
	.DRW	BOBS20
	.DB	1,0
	.DB	SKIP
	.DRW	BOBS10	

BOBS20:	.DB	SETMOM,-40,0		;GO ACROSS SCREEN
	.DB	TESTSOLID
	.DRW	BOBS10
	.DB	-1,0
	.DB	SKIP
	.DRW	BOBS20	

	
BOBS34:	.DB	XTRACK,TOWARDS
BOBS35:	.DB	SETMOM,24,0
	.DB	SKIP
	.DRW	BOBS35	

	
BOBSTHURT:
	.DB	INSTRUCTIONS,4
	.DB	FETCHREG,ATTACKER
	.DB	CASE
	.DRW	SAFEDIE,43
	.DRW	SAFEDIE,1
	.DRW	0
	.DB	SETMOM,0,0
	.DB	DELAY,45
	.DB	ACTIVATE,EWAKE	


;---------------------------------------------------------------------
	.DRW	SQUDISS		;39
	.DB	0
	.DRW	SQUBYE1		;36
	.DB	0
	.DRW	SQUSW5		;33
	.DB	0
	.DRW	SQUSW4		;30
	.DB	0
	.DRW	SQUSW3		;27
	.DB	0
	.DRW	SQUSW2	        ;24	
	.DB	0
	.DRW	SQUSW1 		;21
	.DB	0
	.DRW	SQUHIT3
	.DB	0
	.DRW	SQUHIT2
	.DB	0
	.DRW	SQUHIT1
	.DB	0
	.DRW	SQU3HI	     		;SMALLEST
	.DB	0
	.DRW	SQU2HI	       		;MEDIUM
	.DB	0
	.DRW	SQU1HI	  		;BIGGEST
	.DB	0
SQUISHI:
	.DRW	DUMMY,SQUCODE
	.DB	0,-1,0,0,0
	.DRW	DUMMY,SQUHURT
	.DB	0,-1,0,0,0

SQUCODE:
	.DB	INSTRUCTIONS,6
	.DB	GRAVITY,0
	.DB	IDENTIFY
	.DRW	ENEMY
	.DB	MOMLIMIT,96,96
	.DB	SETREG,0,0 	    	;ZERO BOSS
	.DB	STORE,58
	.DB	SOLIDSTATE,OFF
SQU0A:	.DB	YVISUAL		;IF BORN ABOVE SOLID
	.DRW	SQU17
	.DB	88
	.DB	SOLIDSTATE,ON
SQU0:	.DB	ENABLE,HURTING
	.DB	FETCHREG,PARAM2
	.DB	CASE
	.DRW	SQU1,1 		;BIGGEST
	.DRW	SQU2,2		;MEDIUM
	.DRW	SQU3,3		;SMALL
	.DRW	0
SQU1: 	.DB	ANIMATION,3,RESERVE	
	.DB	LOAD,58	
	.DB	EQUAL
	.DRW	SQU8
	.DRW	2

	.DB	INSTRUCTIONS,9
	.DB	DISABLE,HURTING
	.DB	SETMOM,0,0
	.DB	WRITEVID	       
	.DRW	SQUPICK
	.DB	10,9,0,15
	.DB	DELAY,80
	.DB	WRITEVID	       
	.DRW	ERASE
	.DB	10,9,0,15
	.DB	SETREG,2,0
	.DB	STORE,58
	.DB	ENABLE,HURTING
	.DB	SKIP
	.DRW	SQU8

SQU2:	.DB	ANIMATION,6,RESERVE	
	.DB	SKIP
	.DRW	SQU8
SQU3:	.DB	ANIMATION,9,RESERVE	


;MAJOR MOVEMENT CODE START
SQU8: 	.DB	RANDOM
	.DRW	SQU8A
	.DB	200

	.DB	LAUNCH,50,16,8,0	

SQU8A:	.DB	RANDOM
	.DRW	SQU20
	.DB	127	
	
	.DB	INSTRUCTIONS,5
	.DB	FETCHREG,RANDOM
	.DB	ANDREG
	.DRW	H'03
	.DB	CASE
	.DRW	SQU10,0
	.DRW	SQU12,1
	.DRW	SQU14,2
	.DRW	SQU16,3
	.DRW	0

SQU10: 	.DB	SETMOM,0,-96		;NORTH
	.DB	SKIP
	.DRW	SQU8			

SQU12:	.DB	SETMOM,-96,-96		;NORTH WEST
	.DB	SKIP
	.DRW	SQU8			

SQU14:	.DB	SETMOM,-96,0		;WEST
	.DB	SKIP
	.DRW	SQU8			

SQU16:	.DB	SETMOM,-96,96		;SOUTH WEST
	.DB	SKIP
	.DRW	SQU8			

SQU17:	.DB	SETMOM,-1,96 
	.DB	SKIP
	.DRW	SQU0A

SQU20:	.DB	INSTRUCTIONS,5	
	.DB	FETCHREG,RANDOM
	.DB	ANDREG
	.DRW	H'03
	.DB	CASE
	.DRW	SQU22,0
	.DRW	SQU24,1
	.DRW	SQU26,2
	.DRW	SQU28,3
	.DRW	0

SQU22:	.DB	SETMOM,0,96		;SOUTH
	.DB	SKIP
	.DRW	SQU29			

SQU24:	.DB	SETMOM,96,96		;SOUTH EAST
	.DB	SKIP
	.DRW	SQU29		

SQU26:	.DB	SETMOM,96,0		;EAST
	.DB	SKIP
	.DRW	SQU8			

SQU28:	.DB	SETMOM,96,-96		;NORTH EAST
	.DB	SKIP
	.DRW	SQU8			

SQU29:	.DB	BVIRTUAL
	.DRW	SQU29A
	.DRW	144
	.DB	SKIP
	.DRW	SQU8
SQU29A:	.DB	SETMOM,-1,-96
	.DB	SKIP
	.DRW	SQU29

;MAJOR MOVEMENT CODE END


SQU27:	.DB	LOAD,21 	
	.DB	GOTO,8,REGISTER
	.DB	SKIP
	.DRW	SQU8

SQUFRK2:.DB	INSTRUCTIONS,7 
	.DB	FETCHREG,PARAM2
	.DB	CASE
	.DRW	SQU50,1	    		;BIGGEST
	.DRW	SQU55,2			;MEDIUM
	.DRW	SQU56,3			;SMALL
	.DRW	0

;WHEN HE DIES HE LAUNCHES A SMALLER VERSION OF HIMSELF

SQU50:
	.DB	DELAY,20 
	.DB	ANIMATION,21,RESERVE
	.DB	DELAY,3	
	.DB	ANIMATION,24,RESERVE
	.DB	DELAY,3	
	.DB	NOISE
	.DRW	CHNGSND
	.DB	LAUNCH,49,0,0,2		;MEDIUM GUY
	.DB	LAUNCH,49,0,0,2		;MEDIUM GUY
	.DB	DELAY,3	
	.DB	DIE,0
SQU55:
	.DB	DELAY,20	
	.DB	ANIMATION,27,RESERVE
	.DB	DELAY,3	
	.DB	ANIMATION,30,RESERVE
	.DB	DELAY,3	
	.DB	NOISE
	.DRW	CHNGSND
	.DB	LAUNCH,49,0,0,3		;MEDIUM GUY
	.DB	LAUNCH,49,0,0,3		;MEDIUM GUY
	.DB	DIE,0
SQU56: 	.DB	HURT,0,ID
	.DRW 	50			;GET RID OF BOMBS 
	.DB	DELAY,20
	.DB	ANIMATION,33,RESERVE
	.DB	DELAY,3
	.DB	ANIMATION,30,RESERVE
	.DB	DELAY,3
	.DB	ANIMATION,27,RESERVE
	.DB	DELAY,3
	.DB	ANIMATION,24,RESERVE
	.DB	DELAY,3
	.DB	ANIMATION,21,RESERVE
	.DB	DELAY,3

	.DB	ANIMATION,36,RESERVE
	.DB	NOISE
	.DRW	SQSHDIE
	.DB	SETCOUNTER,60
SQU57:	.DB	PALCLR,0,H'30
	.DB	PALCLR,0,H'21
	.DB	PALCLR,0,H'07
	.DB	PALCLR,0,H'3A
	.DB	ABOVECOUNT
	.DRW	SQU57
	.DB	0
	.DB	BPALETTE
	.DRW	-1	
	.DB	ANIMATION,21,RESERVE
	.DB	DELAY,3
	.DB	ANIMATION,24,RESERVE
	.DB	DELAY,3
	.DB	ANIMATION,27,RESERVE
	.DB	DELAY,3
	.DB	ANIMATION,30,RESERVE
	.DB	DELAY,3
	.DB	ANIMATION,33,RESERVE
	.DB	DELAY,3
	.DB	ANIMATION,39,RESERVE
	.DB	DELAY,3
	.DB	LAUNCH,52,0,0,0		;MAKE STAR
	.DB	DIE,0

SQUHURT:.DB	INSTRUCTIONS,4
	.DB	NOISE
	.DRW	SQSHHURT
	.DB	FETCHREG,PARAM2	   		
	.DB	CASE
	.DRW	SQU30,1		;BIG
	.DRW	SQU35,2		;MED
	.DRW	SQU36,3		;SMALL
	.DRW	0

;HURT PICTURES ONLY    
;EACH HAS OWN HURT PICTURE	

SQU30:	.DB	ANIMATION,12,RESERVE
	.DB	SKIP
	.DRW	SQU60
SQU35:	.DB	ANIMATION,15,RESERVE
	.DB	SKIP
	.DRW	SQU60
SQU36:	.DB	ANIMATION,18,RESERVE

SQU60:	.DB	SETMOM,0,0
	.DB	DAMAGE
	.DB	ASSESS
	.DRW	SQUFRK2
	.DB	0
	.DB	DELAY,30
	.DB	SKIP
	.DRW	SQU0

ENDING:
	.DB	-1
	.DRW	H'2142
	.DB	"    NICE SHOOTIN', TEX!"
	.DB	-2  
	.DRW	H'0060		;Y OFFSET	
	.DB	"YOU'VE SENT SQUISHI BACK TO"
	.DB	-2  
	.DRW	H'0040		;Y OFFSET	
	.DB	"WHERE HE BELONGS AND TURNED"
	.DB	-2  
	.DRW	H'0040		;Y OFFSET	
	.DB	"  THE QUIRKS INTO HAPPY,"
	.DB	-2  
	.DRW	H'0040		;Y OFFSET	
	.DB	"  NORMAL CITIZENS, AGAIN!"
	.DB	-2  
	.DRW	H'0060		;Y OFFSET	
	.DB	"  LET'S ALL GATHER 'ROUND"
	.DB	-2  
	.DRW	H'0040		;Y OFFSET	
	.DB	" AND STRIKE UP THE BAND..."
	.DB	0  

SQUPICK:
	.DB	"I HATE PICKLES!"

;---------------------------------------------------------------------


	.DRW	SQFLAMS
	.DB	0
SQUIBOMB:
	.DRW	DUMMY,SQBCODE
	.DB	0,-2,0,0,0
	.DRW	-1,SAFEDIE
	.DB	0,-1,0,0,0

SQBCODE:
	.DB	ACTIVE
	.DRW	SAFEDIE
	.DB	ID
	.DRW	50
	.DB	ANIMATION,3,RESERVE
	.DB	GRAVITY,0
	.DB	FRICTION,0,0
	.DB	SOLIDSTATE,OFF
	.DB	IDENTIFY
	.DRW	DEADLY
	.DB	TARGET
	.DRW	HERO0
	.DB	MOMLIMIT,32,72
	.DB	ENABLE,HURTING
;	.DB	NOISE
;	.DRW	SQUSHOT

SQB10:	.DB	SETMOM,0,24 
	.DB	YVISUAL
	.DRW	SQB10
	.DB	208


	.DB	FETCHREG,XDIR
	.DB	CASE
	.DRW	SQB15,0		;GO RIGHT	
	.DRW	SQB20,1		;GO LEFT
	.DRW	0	

SQB15:	.DB	INSTRUCTIONS,8
	.DB	GRAVITY,0
	.DB	SETMOM,32,-56
	.DB	LOWNOISE
	.DRW	JUMPSND
	.DB	DELAY,4
	.DB	GRAVITY,-1
SQB16: 	.DB	ATTACKED
	.DRW	SAFEDIE
	.DB	IFXEDGE
	.DRW	SAFEDIE
	.DB	16
	.DB	YVISUAL
	.DRW	SQB16
	.DB	200
	.DB	SKIP
	.DRW	SQB15	

SQB20:	.DB	INSTRUCTIONS,8
	.DB	GRAVITY,0
	.DB	SETMOM,-32,-56
	.DB	LOWNOISE
	.DRW	JUMPSND
	.DB	DELAY,4
	.DB	GRAVITY,-1
SQB25: 	.DB	ATTACKED
	.DRW	SAFEDIE
	.DB	IFXEDGE
	.DRW	SAFEDIE
	.DB	16
	.DB	YVISUAL
	.DRW	SQB25
	.DB	200
	.DB	SKIP
	.DRW	SQB20	


;---------------------------------------------------------------------

STAR:	.DRW	SQUSTAR3,STARCODE
	.DB	0,-1,0,0,0

STARCODE:
	.DB	GRAVITY,0
STAR10:	.DB	SKIP
	.DRW	STAR10

;----------------------------------------------------------------------------	
;THIS TABLE HAS THE VALUE TO SET FOR SUPERSOLID FOR A GIVEN WORLD.  THIS
;VALUE NEVER BECOMES UNSOLID.  THE DEFAULT ENTITY SOLID VALUE IS TURNED
;OFF WHEN THE ENTITY JUMPS UP OR DOWN.  ALL ENTITIES USE THIS VALUE.

SOLIDSVAL:
	.DB	H'FF	;0
	.DB	H'FF	;1	
	.DB	H'FF	;2	
	.DB	H'FF	;3	
	.DB	H'FF	;4	
	.DB	H'FF	;5	
	.DB	H'FF	;6	
	.DB	H'FF	;7	
	.DB	H'FF	;8	
	.DB	H'FF	;9	
	.DB	H'FF	;10	
	.DB	H'FF	;11	
	.DB	H'FF	;12	
	.DB	H'FF	;13	
	.DB	H'FF	;14	
	.DB	H'FF	;15	
	.DB	H'FF	;16	
	.DB	H'FF	;17	
	.DB	H'FF	;18	
	.DB	H'FF	;19	
	.DB	H'FF	;20	

;THIS TABLE HAS THE LOW SOLIDS VALUE FOR A GIVEN WORLD.  THE ENTITYTAB
;ENTRY NORMALLY HOLDS THIS LOW VALUE BUT WE NEEDED IT TO VARY IN SOME
;WORLDS.  RIGHT NOW, ENTITIES IGNORE THIS AND USE THEIR OWN, ONLY
;THE HERO USES THIS ONE.

LOWSOLIDS:
	.DB	H'E0	;0
	.DB	H'E0	;1 
	.DB	H'E0	;2 
	.DB	H'E0	;3 
	.DB	H'E0	;4 
	.DB	H'E0	;5 
	.DB	H'E0	;6 
	.DB	H'E0	;7 
	.DB	H'E0	;8 
	.DB	H'E0	;9 
	.DB	H'E0	;10 
	.DB	H'E0	;11
	.DB	H'E0	;12
	.DB	H'E0	;13
	.DB	H'E0	;14
	.DB	H'E0	;15
	.DB	H'E0	;16
	.DB	H'E0	;17
	.DB	H'E0	;18
	.DB	H'E0	;19
	.DB	H'E0	;20
 
;---------------------------------------------------------------------

